[gvfs] Use g_poll instead of poll in metatree.c



commit 52ab4355f74a0862815ce2d29a6388830c2cb244
Author: Christian Kellner <gicmo gnome org>
Date:   Sun Feb 14 18:53:25 2010 +0100

    Use g_poll instead of poll in metatree.c
    
    Patch by "paul <ephraim_owns hotmail com>" Fixes bug #60468.

 metadata/metatree.c |    7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)
---
diff --git a/metadata/metatree.c b/metadata/metatree.c
index 2820fb5..3a1c12b 100644
--- a/metadata/metatree.c
+++ b/metadata/metatree.c
@@ -51,7 +51,6 @@
 #include <glib.h>
 #include <glib/gstdio.h>
 #include <errno.h>
-#include <poll.h>
 #include "crc32.h"
 
 #ifdef HAVE_LIBUDEV
@@ -2989,7 +2988,7 @@ update_mountinfo (void)
   char *contents;
   int res;
   gboolean first;
-  struct pollfd pfd;
+  GPollFD pfd;
 
   first = FALSE;
   if (!mountinfo_initialized)
@@ -3005,9 +3004,9 @@ update_mountinfo (void)
   if (!first)
     {
       pfd.fd = mountinfo_fd;
-      pfd.events = POLLIN | POLLOUT | POLLPRI;
+      pfd.events = G_IO_IN | G_IO_OUT | G_IO_PRI;
       pfd.revents = 0;
-      res = poll (&pfd, 1, 0);
+      res = g_poll (&pfd, 1, 0);
       if (res == 0)
 	return;
     }



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]