Rename g_unix_pipe_flags to g_unix_open_pipe
authorColin Walters <walters@verbum.org>
Tue, 3 May 2011 20:31:34 +0000 (16:31 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Wed, 4 May 2011 03:34:17 +0000 (23:34 -0400)
From IRC discussion, people liked this name more.

https://bugzilla.gnome.org/show_bug.cgi?id=649322

docs/reference/glib/glib-sections.txt
gio/gcancellable.c
glib/glib-unix.c
glib/glib-unix.h
glib/glib.symbols
glib/gmain.c
glib/tests/unix.c

index 6bf8593..de8f4ae 100644 (file)
@@ -1928,7 +1928,7 @@ g_win32_ftruncate
 <TITLE>UNIX-specific utilities and integration</TITLE>
 <FILE>gunix</FILE>
 G_UNIX_ERROR
-g_unix_pipe_flags
+g_unix_open_pipe
 g_unix_signal_source_new
 g_unix_signal_add_watch_full
 
index 5a078b4..3573ee8 100644 (file)
@@ -199,7 +199,7 @@ g_cancellable_open_pipe (GCancellable *cancellable)
   GCancellablePrivate *priv;
 
   priv = cancellable->priv;
-  if (g_unix_pipe_flags (priv->cancel_pipe, FD_CLOEXEC, NULL))
+  if (g_unix_open_pipe (priv->cancel_pipe, FD_CLOEXEC, NULL))
     {
       /* Make them nonblocking, just to be sure we don't block
        * on errors and stuff
index d88455a..7471ddb 100644 (file)
@@ -74,7 +74,7 @@ g_unix_set_error_from_errno_saved (GError **error,
 }
 
 /**
- * g_unix_pipe_flags:
+ * g_unix_open_pipe:
  * @fds: Array of two integers
  * @flags: Bitfield of file descriptor flags, see "man 2 fcntl"
  * @error: a #GError
@@ -93,9 +93,9 @@ g_unix_set_error_from_errno_saved (GError **error,
  * Since: 2.30
  */
 gboolean
-g_unix_pipe_flags (int     *fds,
-                  int      flags,
-                  GError **error)
+g_unix_open_pipe (int     *fds,
+                 int      flags,
+                 GError **error)
 {
   int ecode;
 
index c85a277..d1e5ca2 100644 (file)
@@ -57,9 +57,9 @@
 
 GQuark g_unix_error_quark (void);
 
-gboolean g_unix_pipe_flags (gint      *fds,
-                           gint       flags,
-                           GError   **error);
+gboolean g_unix_open_pipe (gint      *fds,
+                          gint       flags,
+                          GError   **error);
 
 gboolean g_unix_set_fd_nonblocking (gint       fd,
                                    gboolean   nonblock,
index 12b7430..08b2f17 100644 (file)
@@ -1981,8 +1981,8 @@ g_hostname_to_unicode
 #if IN_HEADER(__G_UNIX_H__)
 #if IN_FILE(__G_UNIX_C__)
 #ifdef G_OS_UNIX
-g_unix_pipe_flags
 g_unix_error_quark
+g_unix_open_pipe
 g_unix_set_fd_nonblocking
 g_unix_signal_source_new
 g_unix_signal_add_watch_full
index efcdcc3..25b9310 100644 (file)
@@ -560,7 +560,7 @@ g_main_context_init_pipe (GMainContext *context)
   if (context->wake_up_pipe[0] != -1)
     return;
 
-  if (!g_unix_pipe_flags (context->wake_up_pipe, FD_CLOEXEC, &error))
+  if (!g_unix_open_pipe (context->wake_up_pipe, FD_CLOEXEC, &error))
     g_error ("Cannot create pipe main loop wake-up: %s", error->message);
 
   context->wake_up_rec.fd = context->wake_up_pipe[0];
@@ -4636,7 +4636,7 @@ init_unix_signal_wakeup_state_unlocked (void)
   if (unix_signal_init_state == UNIX_SIGNAL_INITIALIZED_THREADED)
     return;
 
-  if (!g_unix_pipe_flags (unix_signal_wake_up_pipe, FD_CLOEXEC, &error))
+  if (!g_unix_open_pipe (unix_signal_wake_up_pipe, FD_CLOEXEC, &error))
     g_error ("Cannot create UNIX signal wake up pipe: %s\n", error->message);
   g_unix_set_fd_nonblocking (unix_signal_wake_up_pipe[1], TRUE, NULL);
 
index 065deb1..e1664e4 100644 (file)
@@ -34,7 +34,7 @@ test_pipe (void)
   char buf[1024];
   ssize_t bytes_read;
 
-  g_unix_pipe_flags (pipefd, FD_CLOEXEC, NULL);
+  g_unix_open_pipe (pipefd, FD_CLOEXEC, NULL);
   g_assert_no_error (error);
     
   write (pipefd[1], "hello", sizeof ("hello"));