comparison mercurial/mpatch.c @ 551:b460a2fd8bb7

[PATCH] bdiff/mpatch under MSVC -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 [PATCH] bdiff/mpatch under MSVC From: K Thananchayan <thananck@yahoo.com> MSVC (6.0) environment does not have 'stdint.h' and does not provide `inline' qualifier. The following patch is needed to make mecurial installable under MSVC. manifest hash: a5b64235acced16cb451faa698922559fec4e573 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) iD8DBQFCxPapywK+sNU5EO8RAmRnAKCt9cOASaIsYB6kNUDSIStR1DmY4gCgnXlL Jf0nMmGEkoyXtB0eV+fLzJU= =fKD5 -----END PGP SIGNATURE-----
author mpm@selenic.com
date Thu, 30 Jun 2005 23:54:17 -0800
parents 7f3fc8fd427e
children f2442a6a5893
comparison
equal deleted inserted replaced
550:96ff7dae94f7 551:b460a2fd8bb7
22 22
23 #include <Python.h> 23 #include <Python.h>
24 #include <stdlib.h> 24 #include <stdlib.h>
25 #include <string.h> 25 #include <string.h>
26 #ifdef _WIN32 26 #ifdef _WIN32
27 #ifdef _MSC_VER
28 #define inline __inline
29 typedef unsigned long uint32_t;
30 #else
27 #include <stdint.h> 31 #include <stdint.h>
32 #endif
28 static uint32_t ntohl(uint32_t x) 33 static uint32_t ntohl(uint32_t x)
29 { 34 {
30 return ((x & 0x000000ffUL) << 24) | 35 return ((x & 0x000000ffUL) << 24) |
31 ((x & 0x0000ff00UL) << 8) | 36 ((x & 0x0000ff00UL) << 8) |
32 ((x & 0x00ff0000UL) >> 8) | 37 ((x & 0x00ff0000UL) >> 8) |