Small bug in gdkmain-x11.c



There is small bug in _gdk_windowing_init_check causing a segfault when
gtk_init as called with NULL args.

The following patch should fix this, but I don't now if this is the
correct solution.

--- gdkmain-x11.c.orig  Thu Aug 10 00:46:35 2000
+++ gdkmain-x11.c       Thu Aug 10 00:45:47 2000
@@ -166,7 +166,7 @@
                                          10, 10, 10, 10, 0, 0 , 0);
   class_hint = XAllocClassHint();
   class_hint->res_name = g_get_prgname ();
-  if (gdk_progclass == NULL)
+  if (gdk_progclass == NULL && g_get_prgname ())
     {
       gdk_progclass = g_strdup (g_get_prgname ());
       gdk_progclass[0] = toupper (gdk_progclass[0]);

-- 
Espen




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]