about summary refs log tree commit homepage
path: root/ext/sleepy_penguin/splice.c
diff options
context:
space:
mode:
Diffstat (limited to 'ext/sleepy_penguin/splice.c')
-rw-r--r--ext/sleepy_penguin/splice.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/ext/sleepy_penguin/splice.c b/ext/sleepy_penguin/splice.c
index d291796..ab8c1ff 100644
--- a/ext/sleepy_penguin/splice.c
+++ b/ext/sleepy_penguin/splice.c
@@ -149,6 +149,10 @@ void sleepy_penguin_init_splice(void)
          * fcntl() command constant used to return the size of a pipe.
          * This constant is only defined when running Linux 2.6.35
          * or later.
+         *
+         *        require 'fcntl'
+         *        r, w = IO.pipe
+         *        r.fcntl(SleepyPenguin::F_GETPIPE_SZ) => Integer
          */
         rb_define_const(mod, "F_GETPIPE_SZ", UINT2NUM(F_GETPIPE_SZ));
 
@@ -156,6 +160,12 @@ void sleepy_penguin_init_splice(void)
          * fcntl() command constant used to set the size of a pipe.
          * This constant is only defined when running Linux 2.6.35
          * or later.
+         *
+         * call-seq:
+         *
+         *        require 'fcntl'
+         *        r, w = IO.pipe
+         *        r.fcntl(SleepyPenguin::F_SETPIPE_SZ, 131072)
          */
         rb_define_const(mod, "F_SETPIPE_SZ", UINT2NUM(F_SETPIPE_SZ));