mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-08-01 23:13:40 +02: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:
committed by
David Zeuthen
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
|
||||
|
Reference in New Issue
Block a user