diff options
Diffstat (limited to 'lang/ruby18-base/patches/patch-az')
-rw-r--r-- | lang/ruby18-base/patches/patch-az | 48 |
1 files changed, 39 insertions, 9 deletions
diff --git a/lang/ruby18-base/patches/patch-az b/lang/ruby18-base/patches/patch-az index b31ba889a60..87fbe939dbb 100644 --- a/lang/ruby18-base/patches/patch-az +++ b/lang/ruby18-base/patches/patch-az @@ -1,13 +1,43 @@ -$NetBSD: patch-az,v 1.1 2005/09/18 13:38:50 taca Exp $ +$NetBSD: patch-az,v 1.2 2005/11/02 08:56:40 taca Exp $ ---- io.c.orig 2004-12-25 19:56:39.000000000 +0900 +--- io.c.orig 2005-09-20 17:11:35.000000000 +0900 +++ io.c -@@ -32,7 +32,7 @@ - # define NO_LONG_FNAME - #endif - --#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(sun) || defined(_nec_ews) -+#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__) || defined(sun) || defined(_nec_ews) - # define USE_SETVBUF +@@ -1020,8 +1020,10 @@ read_buffered_data(ptr, len, f) + if (n > len) n = len; + return fread(ptr, 1, n, f); + #else +- for (n = 0; n < len && READ_DATA_PENDING(f); ++n) { +- *ptr++ = getc(f); ++ int c; ++ ++ for (n = 0; n < len && READ_DATA_PENDING(f) && (c = getc(f)) != EOF; ++n) { ++ *ptr++ = c; + } + return n; #endif +@@ -3516,6 +3518,7 @@ rb_io_reopen(argc, argv, file) + return file; + } ++/* :nodoc: */ + static VALUE + rb_io_init_copy(dest, io) + VALUE dest, io; +@@ -3632,7 +3635,7 @@ rb_f_printf(argc, argv) + * ios.print(obj, ...) => nil + * + * Writes the given object(s) to <em>ios</em>. The stream must be +- * opened for writing. If the output record separator (<code>$\</code>) ++ * opened for writing. If the output record separator (<code>$\\</code>) + * is not <code>nil</code>, it will be appended to the output. If no + * arguments are given, prints <code>$_</code>. Objects that aren't + * strings will be converted by calling their <code>to_s</code> method. +@@ -3688,7 +3691,7 @@ rb_io_print(argc, argv, out) + * Prints each object in turn to <code>$stdout</code>. If the output + * field separator (<code>$,</code>) is not +nil+, its + * contents will appear between each field. If the output record +- * separator (<code>$\</code>) is not +nil+, it will be ++ * separator (<code>$\\</code>) is not +nil+, it will be + * appended to the output. If no arguments are given, prints + * <code>$_</code>. Objects that aren't strings will be converted by + * calling their <code>to_s</code> method. |