Skip to content

Commit 193e2b1

Browse files
committed
squash! S_IFDIR -> _S_IFDIR
1 parent 2776ef8 commit 193e2b1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

quickjs-libc.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2050,7 +2050,7 @@ static JSValue js_os_remove(JSContext *ctx, JSValueConst this_val,
20502050
#if defined(_WIN32)
20512051
{
20522052
struct stat st;
2053-
if (stat(filename, &st) == 0 && S_ISDIR(st.st_mode)) {
2053+
if (stat(filename, &st) == 0 && (st.st_mode & _S_IFDIR)) {
20542054
ret = rmdir(filename);
20552055
} else {
20562056
ret = unlink(filename);

0 commit comments

Comments
 (0)