[Goodies-commits] r6344 - in sion/trunk: . src
Enrico Troeger
enrico at xfce.org
Sun Dec 21 01:47:35 CET 2008
Author: enrico
Date: 2008-12-21 00:47:34 +0000 (Sun, 21 Dec 2008)
New Revision: 6344
Modified:
sion/trunk/ChangeLog
sion/trunk/src/bookmark.c
Log:
Fix crash when parsing an URI without a proper scheme (bug #4730).
Modified: sion/trunk/ChangeLog
===================================================================
--- sion/trunk/ChangeLog 2008-12-20 21:52:03 UTC (rev 6343)
+++ sion/trunk/ChangeLog 2008-12-21 00:47:34 UTC (rev 6344)
@@ -1,3 +1,9 @@
+2008-12-21 Enrico Tröger <enrico(at)xfce(dot)org>
+
+ * src/bookmark.c:
+ Fix crash when parsing an URI without a proper scheme (bug #4730).
+
+
2008-12-19 Enrico Tröger <enrico(at)xfce(dot)org>
* src/Makefile.am, README, configure.ac, Makefile.am, autogen.sh:
Modified: sion/trunk/src/bookmark.c
===================================================================
--- sion/trunk/src/bookmark.c 2008-12-20 21:52:03 UTC (rev 6343)
+++ sion/trunk/src/bookmark.c 2008-12-21 00:47:34 UTC (rev 6344)
@@ -132,6 +132,12 @@
priv->scheme = g_uri_parse_scheme(uri);
s = strstr(uri, "://");
+ if (priv->scheme == NULL || s == NULL)
+ {
+ verbose("Error parsing URI %s while reading URI scheme", uri);
+ bookmark_clear(bm);
+ return FALSE;
+ }
s += 3;
/* find end of host/port, this is the first slash after the initial double slashes */
More information about the Goodies-commits
mailing list