fix compiler warnings

This commit is contained in:
2026-02-20 12:44:18 -06:00
parent 54e5be0773
commit c0aff9e9bf
13 changed files with 33 additions and 24 deletions

View File

@@ -146,7 +146,6 @@ static JSValue js_enet_host_service(JSContext *ctx, JSValueConst this_val, int a
if (!host) return JS_EXCEPTION;
if (argc < 1 || !JS_IsFunction(argv[0])) return JS_RaiseDisrupt(ctx, "Expected a callback function as first argument");
JSValue callback = JS_DupValue(ctx, argv[0]);
double secs;
JS_ToFloat64(ctx, &secs, argv[1]);
@@ -186,7 +185,6 @@ static JSValue js_enet_host_service(JSContext *ctx, JSValueConst this_val, int a
JS_FreeValue(ctx, event_obj);
}
JS_FreeValue(ctx, callback);
return JS_NULL;
}

View File

@@ -226,7 +226,10 @@ static int par_easycurl_to_memory(char const *url, par_byte **data, int *nbytes)
CFRelease(cfurlRef);
if (!request) return 0;
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
CFReadStreamRef stream = CFReadStreamCreateForHTTPRequest(NULL, request);
#pragma clang diagnostic pop
CFRelease(request);
if (!stream) return 0;