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 764057 - Add soup_socket_listen_full() to propagate errors
Add soup_socket_listen_full() to propagate errors
Status: RESOLVED FIXED
Product: libsoup
Classification: Core
Component: API
unspecified
Other Linux
: Normal normal
: ---
Assigned To: libsoup-maint@gnome.bugs
libsoup-maint@gnome.bugs
Depends on:
Blocks:
 
 
Reported: 2016-03-23 08:40 UTC by Stef Walter
Modified: 2016-04-25 20:57 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Add SOUP_AVAILABLE_IN_2_56 definition for new APIs (897 bytes, patch)
2016-03-23 08:40 UTC, Stef Walter
rejected Details | Review
Add soup_socket_listen_full() API which returns an error (3.17 KB, patch)
2016-03-23 08:40 UTC, Stef Walter
needs-work Details | Review
Use soup_socket_listen_full() internally to propagate errors (1.34 KB, patch)
2016-03-23 08:40 UTC, Stef Walter
committed Details | Review
Add soup_socket_listen_full() internal API which returns an error (2.62 KB, patch)
2016-03-23 14:05 UTC, Stef Walter
committed Details | Review

Description Stef Walter 2016-03-23 08:40:18 UTC
Otherwise functions like soup_server_listen_all() don't return an appropriate error when things fail.
Comment 1 Stef Walter 2016-03-23 08:40:35 UTC
Created attachment 324573 [details] [review]
Add SOUP_AVAILABLE_IN_2_56 definition for new APIs
Comment 2 Stef Walter 2016-03-23 08:40:39 UTC
Created attachment 324574 [details] [review]
Add soup_socket_listen_full() API which returns an error

The fact that soup_socket_listen() doesn't return a proper
error masks real failure modes.
Comment 3 Stef Walter 2016-03-23 08:40:44 UTC
Created attachment 324575 [details] [review]
Use soup_socket_listen_full() internally to propagate errors

Otherwise functions like soup_server_listen_all() don't return
an appropriate error when things fail.
Comment 4 Dan Winship 2016-03-23 12:00:55 UTC
Comment on attachment 324574 [details] [review]
Add soup_socket_listen_full() API which returns an error

SoupSocket is deprecated-ish and API-frozen; any new APIs needed internally should be added to soup-socket-private.h.
Comment 5 Dan Winship 2016-03-23 12:03:39 UTC
Comment on attachment 324573 [details] [review]
Add SOUP_AVAILABLE_IN_2_56 definition for new APIs

This needs SOUP_VERSION_2_56 and SOUP_DEPRECATED_IN_2_56 too, but since we won't actually be adding any new public API, let's just drop this patch and then this can go into both master and stable. (Meaning "we don't have to branch yet".)
Comment 6 Stef Walter 2016-03-23 14:05:25 UTC
Created attachment 324590 [details] [review]
Add soup_socket_listen_full() internal API which returns an error

The fact that soup_socket_listen() doesn't return a proper
error masks real failure modes.
Comment 7 Dan Winship 2016-04-25 20:57:38 UTC
Attachment 324575 [details] pushed as c1866cc - Use soup_socket_listen_full() internally to propagate errors
Attachment 324590 [details] pushed as 9d42006 - Add soup_socket_listen_full() internal API which returns an error