Don't ref a NULL pointer
authorРуслан Ижбулатов <lrn1986@gmail.com>
Wed, 24 Jun 2015 10:07:15 +0000 (10:07 +0000)
committerРуслан Ижбулатов <lrn1986@gmail.com>
Thu, 2 Jul 2015 11:03:47 +0000 (11:03 +0000)
gio/gwin32appinfo.c

index 782e153cbd11e5d44a540afc3b82558b2570957c..a883b2475972660f35193c3d7a78a012b1b0af2f 100644 (file)
@@ -3526,7 +3526,7 @@ g_win32_app_info_new_from_app (GWin32AppInfoApplication *app,
 
   new_info->supported_types[i] = NULL;
 
-  new_info->handler = g_object_ref (handler);
+  new_info->handler = handler ? g_object_ref (handler) : NULL;
 
   return G_APP_INFO (new_info);
 }