summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorColin Walters <walters@verbum.org>2009-06-18 16:44:14 -0400
committerColin Walters <walters@verbum.org>2009-06-18 16:45:17 -0400
commitb8af0c1b8b85af36d8abecaee23e117a7d58cc21 (patch)
tree4ed7b0c79952de79b46a2adc5236945828e4994d
parente7771b4eb096fb61aaf5e3520c6b58be66adb234 (diff)
downloadgnome-shell-b8af0c1b8b85af36d8abecaee23e117a7d58cc21.tar.gz
Fix refcounting issue in ShellTextureCache
Also clean up compilation warnings.
-rw-r--r--src/shell-texture-cache.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/shell-texture-cache.c b/src/shell-texture-cache.c
index 5af4cb0a0..eaf9b36da 100644
--- a/src/shell-texture-cache.c
+++ b/src/shell-texture-cache.c
@@ -337,7 +337,7 @@ load_pixbuf_thread (GSimpleAsyncResult *result,
AsyncIconLookupData *data;
GError *error = NULL;
- data = g_object_get_data (result, "load_icon_pixbuf_async");
+ data = g_object_get_data (G_OBJECT (result), "load_icon_pixbuf_async");
if (data->uri)
pixbuf = impl_load_pixbuf_file (data->uri, data->width, data->height, &error);
@@ -382,7 +382,7 @@ load_icon_pixbuf_async (ShellTextureCache *cache,
result = g_simple_async_result_new (G_OBJECT (cache), callback, user_data, load_icon_pixbuf_async);
- g_object_set_data_full (result, "load_icon_pixbuf_async", data, icon_lookup_data_destroy);
+ g_object_set_data_full (G_OBJECT (result), "load_icon_pixbuf_async", data, icon_lookup_data_destroy);
g_simple_async_result_run_in_thread (result, load_pixbuf_thread, G_PRIORITY_DEFAULT, cancellable);
g_object_unref (result);
@@ -408,7 +408,7 @@ load_uri_pixbuf_async (ShellTextureCache *cache,
result = g_simple_async_result_new (G_OBJECT (cache), callback, user_data, load_uri_pixbuf_async);
- g_object_set_data_full (result, "load_uri_pixbuf_async", data, icon_lookup_data_destroy);
+ g_object_set_data_full (G_OBJECT (result), "load_uri_pixbuf_async", data, icon_lookup_data_destroy);
g_simple_async_result_run_in_thread (result, load_pixbuf_thread, G_PRIORITY_DEFAULT, cancellable);
g_object_unref (result);
@@ -540,7 +540,7 @@ shell_texture_cache_load_gicon (ShellTextureCache *cache,
AsyncTextureLoadData *data;
data = g_new0 (AsyncTextureLoadData, 1);
- data->icon = icon;
+ data->icon = g_object_ref (icon);
data->icon_info = info;
data->texture = g_object_ref (texture);
data->width = data->height = size;