mirror of
https://github.com/bellard/quickjs.git
synced 2025-12-31 13:49:11 +03:00
Simplify redundant initializers for JS_NewBool()
This commit is contained in:
@@ -1687,7 +1687,7 @@ static JSValue js_os_isatty(JSContext *ctx, JSValueConst this_val,
|
||||
int fd;
|
||||
if (JS_ToInt32(ctx, &fd, argv[0]))
|
||||
return JS_EXCEPTION;
|
||||
return JS_NewBool(ctx, (isatty(fd) != 0));
|
||||
return JS_NewBool(ctx, isatty(fd));
|
||||
}
|
||||
|
||||
#if defined(_WIN32)
|
||||
|
||||
Reference in New Issue
Block a user