aboutsummaryrefslogtreecommitdiff
path: root/tccpe.c
diff options
context:
space:
mode:
authorgrischka <grischka>2016-10-01 20:54:45 +0200
committergrischka <grischka>2016-10-01 20:54:45 +0200
commit0d9f88ea6794edde6c752975be75d3d89c548d53 (patch)
tree2e5e336b52f7adefe7f604f89c89ca48d2fc1246 /tccpe.c
parent2f1174550e9b2356b7cebe9346858b1f1155520e (diff)
downloadtinycc-0d9f88ea6794edde6c752975be75d3d89c548d53.tar.gz
tinycc-0d9f88ea6794edde6c752975be75d3d89c548d53.tar.bz2
libtcc: reimplement option -Wl,[-no]-whöle-archive
- taking advantage of previous commit "incremental -Wl parsing"
Diffstat (limited to 'tccpe.c')
-rw-r--r--tccpe.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tccpe.c b/tccpe.c
index 3e15d91..0e88fa9 100644
--- a/tccpe.c
+++ b/tccpe.c
@@ -1664,7 +1664,7 @@ ST_FUNC int pe_load_file(struct TCCState *s1, const char *filename, int fd)
ret = pe_load_def(s1, fd);
else if (pe_load_res(s1, fd) == 0)
ret = 0;
- else if (read_mem(fd, 0, buf, sizeof buf) && 0 == strncmp(buf, "MZ", 2))
+ else if (read_mem(fd, 0, buf, 4) && 0 == memcmp(buf, "MZ\220", 4))
ret = pe_load_dll(s1, tcc_basename(filename), fd);
return ret;
}