]> wimlib.net Git - wimlib/blobdiff - src/util.h
xml_update_image_info(): Assume streams are resolved
[wimlib] / src / util.h
index 4b75eda2c98001a515101d8a7e9c398250292925..0a2478a58ad4be20091ec83cec2d5dfdebc67e42 100644 (file)
@@ -243,10 +243,10 @@ extern const tchar *
 path_stream_name(const tchar *path);
 
 static inline void
-print_byte_field(const u8 field[], size_t len)
+print_byte_field(const u8 field[], size_t len, FILE *out)
 {
        while (len--)
-               tprintf(T("%02hhx"), *field++);
+               tfprintf(out, T("%02hhx"), *field++);
 }
 
 static inline u32
@@ -279,4 +279,10 @@ wimlib_printf(const tchar *format, ...) FORMAT(printf, 1, 2);
 extern void
 zap_backslashes(tchar *s);
 
+static inline u64
+hash_u64(u64 n)
+{
+       return n * 0x9e37fffffffc0001ULL;
+}
+
 #endif /* _WIMLIB_UTIL_H */