mirror of
https://github.com/QuasarApp/zip.git
synced 2025-05-06 17:19:33 +00:00
fix ftruncate for tcc on Windows (#260)
* fix ftruncate for tcc on Windows * Update zip.c
This commit is contained in:
parent
4f23190324
commit
55b5d810b5
@ -46,6 +46,13 @@
|
|||||||
#define fileno _fileno
|
#define fileno _fileno
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if defined(__TINYC__) && (defined(_WIN32) || defined(_WIN64))
|
||||||
|
#include <io.h>
|
||||||
|
|
||||||
|
#define ftruncate(fd, sz) (-(_chsize_s((fd), (sz)) != 0))
|
||||||
|
#define fileno _fileno
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifndef HAS_DEVICE
|
#ifndef HAS_DEVICE
|
||||||
#define HAS_DEVICE(P) 0
|
#define HAS_DEVICE(P) 0
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user