Skip to content

Commit 6f3af12

Browse files
committed
go back to setmode define
Apparently macOS has a non-standard setmode() func in its unistd.h that conflicts with this fallback, so go back to using a define, but don't bother having it "return" a value since we aren't (currently) checking it.
1 parent 26f53b1 commit 6f3af12

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

compress.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -193,10 +193,8 @@
193193
# define unlink _unlink
194194
# define write _write
195195
#else
196-
static inline int setmode(int fd, int mode)
197-
{
198-
return 0;
199-
}
196+
/* NB: macOS has a setmode() that is different from Windows. */
197+
# define setmode(fd, mode)
200198
#endif
201199

202200
#ifndef LSTAT

0 commit comments

Comments
 (0)