mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-11-09 19:06:15 +01:00
g_cancellable_get_fd: silently return -1 for NULL cancellable
This keeps compatibility with previous behavior. https://bugzilla.gnome.org/show_bug.cgi?id=655598 Signed-off-by: David Zeuthen <davidz@redhat.com>
This commit is contained in:
parent
659ba3d0b3
commit
ee63179b71
@ -348,6 +348,9 @@ g_cancellable_get_fd (GCancellable *cancellable)
|
||||
{
|
||||
GPollFD pollfd;
|
||||
|
||||
if (cancellable == NULL)
|
||||
return -1;
|
||||
|
||||
#ifdef G_OS_WIN32
|
||||
pollfd.fd = -1;
|
||||
#else
|
||||
|
Loading…
Reference in New Issue
Block a user