Skip to content

Commit e92230c

Browse files
author
Joshua Warner
committed
use c++11-conformant _WIN32 test macro
1 parent d47fcdc commit e92230c

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/lzma/main.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
#include <string.h>
55
#include <sys/types.h>
66
#include <sys/stat.h>
7-
#ifdef WIN32
7+
#ifdef _WIN32
88
#include <windows.h>
99
#else
1010
#include <sys/mman.h>
@@ -65,7 +65,7 @@ int main(int argc, const char** argv)
6565
struct stat s;
6666
int r = fstat(fd, &s);
6767
if (r != -1) {
68-
#ifdef WIN32
68+
#ifdef _WIN32
6969
HANDLE fm;
7070
HANDLE h = (HANDLE)_get_osfhandle(fd);
7171

@@ -178,7 +178,7 @@ int main(int argc, const char** argv)
178178
fprintf(stderr, "unable to determine uncompressed size\n");
179179
}
180180

181-
#ifdef WIN32
181+
#ifdef _WIN32
182182
UnmapViewOfFile(data);
183183
#else
184184
munmap(data, size);

src/tools/binary-to-object/main.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
#include <string.h>
1515

1616
#include <sys/stat.h>
17-
#ifdef WIN32
17+
#ifdef _WIN32
1818
#include <windows.h>
1919
#include <io.h>
2020
#else
@@ -120,7 +120,7 @@ int main(int argc, const char** argv)
120120
struct stat s;
121121
int r = fstat(fd, &s);
122122
if (r != -1) {
123-
#ifdef WIN32
123+
#ifdef _WIN32
124124
HANDLE fm;
125125
HANDLE h = (HANDLE)_get_osfhandle(fd);
126126

@@ -157,7 +157,7 @@ int main(int argc, const char** argv)
157157
fprintf(stderr, "unable to open %s\n", argv[2]);
158158
}
159159

160-
#ifdef WIN32
160+
#ifdef _WIN32
161161
UnmapViewOfFile(data);
162162
#else
163163
munmap(data, size);

0 commit comments

Comments
 (0)