[GTK] Don't use the slice allocator
authormcatanzaro@igalia.com <mcatanzaro@igalia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 10 Dec 2018 14:56:16 +0000 (14:56 +0000)
committermcatanzaro@igalia.com <mcatanzaro@igalia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 10 Dec 2018 14:56:16 +0000 (14:56 +0000)
https://bugs.webkit.org/show_bug.cgi?id=192360

Reviewed by Carlos Garcia Campos.

* MiniBrowser/gtk/main.c:
(aboutDataRequestFree):
(aboutDataRequestNew):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@239027 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Tools/ChangeLog
Tools/MiniBrowser/gtk/main.c

index e871b83..2452823 100644 (file)
@@ -1,3 +1,14 @@
+2018-12-10  Michael Catanzaro  <mcatanzaro@igalia.com>
+
+        [GTK] Don't use the slice allocator
+        https://bugs.webkit.org/show_bug.cgi?id=192360
+
+        Reviewed by Carlos Garcia Campos.
+
+        * MiniBrowser/gtk/main.c:
+        (aboutDataRequestFree):
+        (aboutDataRequestNew):
+
 2018-12-10  Tim Horton  <timothy_horton@apple.com>
 
         WKWebView should support custom tintColor
index 6eff950..afbe555 100644 (file)
@@ -268,7 +268,7 @@ static void aboutDataRequestFree(AboutDataRequest *request)
     if (request->dataMap)
         g_hash_table_destroy(request->dataMap);
 
-    g_slice_free(AboutDataRequest, request);
+    g_free(request);
 }
 
 static AboutDataRequest* aboutDataRequestNew(WebKitURISchemeRequest *uriRequest)
@@ -276,7 +276,7 @@ static AboutDataRequest* aboutDataRequestNew(WebKitURISchemeRequest *uriRequest)
     if (!aboutDataRequestMap)
         aboutDataRequestMap = g_hash_table_new_full(g_direct_hash, g_direct_equal, NULL, (GDestroyNotify)aboutDataRequestFree);
 
-    AboutDataRequest *request = g_slice_new0(AboutDataRequest);
+    AboutDataRequest *request = g_new0(AboutDataRequest, 1);
     request->request = g_object_ref(uriRequest);
     g_hash_table_insert(aboutDataRequestMap, GUINT_TO_POINTER(webkit_web_view_get_page_id(webkit_uri_scheme_request_get_web_view(request->request))), request);