aboutsummaryrefslogtreecommitdiff
path: root/util/cbfstool/common.h
diff options
context:
space:
mode:
Diffstat (limited to 'util/cbfstool/common.h')
-rw-r--r--util/cbfstool/common.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/util/cbfstool/common.h b/util/cbfstool/common.h
index ede06e5340..e149444d38 100644
--- a/util/cbfstool/common.h
+++ b/util/cbfstool/common.h
@@ -17,6 +17,12 @@
*/
#include <stdint.h>
+#ifndef WIN32
+#include <arpa/inet.h>
+#else
+#define ntohl(x) (((x)>>24) | ((x)<<24) | (((x)>>8)&0xff00) | (((x)<<8)&0xff0000))
+#define htonl ntohl
+#endif
extern void *offset;
extern struct cbfs_header *master_header;