• Debarshi Ray's avatar
    httpclient: Ensure that the GTask is always cleaned up · 0476f2ed
    Debarshi Ray authored
    The synchronous variant of goa_http_client_check runs a thread-specific
    GMainContext until the asynchronous variant invokes its callback. Once
    the callback is invoked, the GMainLoop is quit. This means that there
    won't be any further iterations of the loop and no new GSources will
    be dispatched.
    
    Therefore, when the synchronous HttpClient gets aborted by the
    GCancellable or due to an SSL error, then the following
    http_client_check_response_cb might not be invoked due to the lack of
    a running GMainLoop to drive the GMainContext; as a result, the GTask
    will get leaked.
    
    Solve this by tracking the GError and returning the GTask only when
    everything is complete.
    
    This was fixed in commit 3b35bd71, but
    broke in commit 73242fa2 when porting
    to GTask.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=764157
    0476f2ed
Name
Last commit
Last update
data Loading commit data...
doc Loading commit data...
m4 Loading commit data...
po Loading commit data...
src Loading commit data...
COPYING Loading commit data...
HACKING Loading commit data...
Makefile.am Loading commit data...
NEWS Loading commit data...
README Loading commit data...
autogen.sh Loading commit data...
configure.ac Loading commit data...
git.mk Loading commit data...
gnome-online-accounts.doap Loading commit data...
meson.build Loading commit data...
meson_options.txt Loading commit data...
meson_post_install.py Loading commit data...