Fix race in g_cancellable_cancel()
authorBenjamin Otte <otte@redhat.com>
Fri, 26 Mar 2010 19:37:09 +0000 (20:37 +0100)
committerRyan Lortie <desrt@desrt.ca>
Mon, 29 Mar 2010 17:57:35 +0000 (12:57 -0500)
commite7763678b56e3be073cc55d707a6e92fc2055ee0
tree02d95a1adf9efdcfdbe15a086f2622d0968969b6
parent5527a2ac2ce2b5bea10867fb2e39d2f1914cfbe6
Fix race in g_cancellable_cancel()

We need to check priv->cancelled after taking the lock. Previously we
only checked it just before taking the lock, which left a small chance
for a race.
gio/gcancellable.c