Applications/Internet/Cyberia.app: Always create JsonObject for headers in each request

This commit is contained in:
Alec Murphy
2025-10-10 14:10:10 -04:00
parent fcbc741137
commit 0266caab91

View File

@@ -667,7 +667,7 @@ U0 @cyberia_navigate(Bool refresh = FALSE)
MemSet(buffer, 0, HTTP_FETCH_BUFFER_SIZE);
@http_response* resp = NULL;
JsonObject* headers = NULL;
JsonObject* headers = Json.CreateObject(browser_task);
U8* domain = renderer->current_url->host;
JsonKey* cookie_keys = NULL;
U8 cookie_buf[2048];
@@ -682,7 +682,6 @@ U0 @cyberia_navigate(Bool refresh = FALSE)
win->focused_widget = addressbar1;
} else {
if (cyberia->o("cookies")->@(domain)) {
headers = Json.CreateObject(browser_task);
cookie_keys = cyberia->o("cookies")->o(domain)->keys;
StrCpy(cookie_buf, "");
while (cookie_keys) {