From 94dc9cd113f5263a55ee86855a4642991f87a351 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Mon, 20 Apr 2015 13:41:07 -0700 Subject: Have a common routine to convert FILETIME to nstime_t. We had several copies of that code; put it into a filetime_to_nstime() routine in wsutil, and call that common routine instead. Change-Id: I1eb5579c36c129ff8d23f9212285ab3f63be0f43 Reviewed-on: https://code.wireshark.org/review/8142 Reviewed-by: Guy Harris --- wsutil/nstime.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'wsutil/nstime.h') diff --git a/wsutil/nstime.h b/wsutil/nstime.h index a74457c8b6..c72daa19c6 100644 --- a/wsutil/nstime.h +++ b/wsutil/nstime.h @@ -102,6 +102,10 @@ WS_DLL_PUBLIC double nstime_to_msec(const nstime_t *nstime); /** converts nstime to double, time base is seconds */ WS_DLL_PUBLIC double nstime_to_sec(const nstime_t *nstime); +/** converts Windows FILETIME to nstime, returns TRUE on success, + FALSE on failure */ +WS_DLL_PUBLIC gboolean filetime_to_nstime(nstime_t *nstime, guint64 filetime); + #ifdef __cplusplus } #endif /* __cplusplus */ -- cgit v1.2.1