yelp r3028 - in trunk: . src



Author: dscorgie
Date: Thu Jan 10 20:44:01 2008
New Revision: 3028
URL: http://svn.gnome.org/viewvc/yelp?rev=3028&view=rev

Log:
* src/yelp-search-parser.c: 
Fix potential crash when comment is NULL


Modified:
   trunk/ChangeLog
   trunk/src/yelp-search-parser.c

Modified: trunk/src/yelp-search-parser.c
==============================================================================
--- trunk/src/yelp-search-parser.c	(original)
+++ trunk/src/yelp-search-parser.c	Thu Jan 10 20:44:01 2008
@@ -1089,7 +1089,10 @@
     container->doc_title = g_strdup ((gchar *) reg->name);
     container->score=0;
     container->html = FALSE;
-    container->default_snippet = g_strdup ((gchar *) reg->comment);
+    if (reg->comment)
+    	container->default_snippet = g_strdup ((gchar *) reg->comment);
+    else
+    	container->default_snippet = g_strdup (_("No Comment"));
     container->current_subsection = NULL;
     container->elem_type = NULL;
 



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