After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 594596 - Fails to parse URI with trailing whitespace
Fails to parse URI with trailing whitespace
Status: RESOLVED DUPLICATE of bug 590524
Product: libsoup
Classification: Core
Component: Misc
2.27.x
Other Linux
: Normal normal
: ---
Assigned To: libsoup-maint@gnome.bugs
libsoup-maint@gnome.bugs
Depends on:
Blocks:
 
 
Reported: 2009-09-09 07:57 UTC by Xan Lopez
Modified: 2009-12-19 14:43 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
strip.patch (4.94 KB, patch)
2009-09-09 08:28 UTC, Xan Lopez
none Details | Review

Description Xan Lopez 2009-09-09 07:57:47 UTC
soup_uri_new will fail parsing "http://192.168.0.1:901 ". Note the space at the end, and the presence of a port. If there's no port ("http://192.168.0.1 ") it will work fine. I guess the obvious fix is to strip all whitespace before parsing...
Comment 1 Xan Lopez 2009-09-09 08:28:11 UTC
Created attachment 142764 [details] [review]
strip.patch

So... like this. dupping the string sucks though, so it might be better to fix the parsing logic to do the right thing. I'd still change all the 'soup_uri_free (uri); return NULL' stuff to just do a goto though :)
Comment 2 Dan Winship 2009-12-19 14:43:30 UTC

*** This bug has been marked as a duplicate of bug 590524 ***