ruby-changes:5406
From: shyouhei <ko1@a...>
Date: Sun, 8 Jun 2008 02:55:12 +0900 (JST)
Subject: [ruby-changes:5406] Ruby:r16909 (ruby_1_8_5): merge revision(s) 13774:
shyouhei 2008-06-08 02:54:58 +0900 (Sun, 08 Jun 2008)
New Revision: 16909
Modified files:
branches/ruby_1_8_5/ChangeLog
branches/ruby_1_8_5/io.c
branches/ruby_1_8_5/version.h
Log:
merge revision(s) 13774:
* io.c (rb_io_tell, rb_io_seek): check errno too. [ruby-dev:32093]
http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/branches/ruby_1_8_5/io.c?r1=16909&r2=16908&diff_format=u
http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/branches/ruby_1_8_5/version.h?r1=16909&r2=16908&diff_format=u
http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/branches/ruby_1_8_5/ChangeLog?r1=16909&r2=16908&diff_format=u
Index: ruby_1_8_5/ChangeLog
===================================================================
--- ruby_1_8_5/ChangeLog (revision 16908)
+++ ruby_1_8_5/ChangeLog (revision 16909)
@@ -1,3 +1,7 @@
+Sun Jun 8 02:54:30 2008 Nobuyoshi Nakada <nobu@r...>
+
+ * io.c (rb_io_tell, rb_io_seek): check errno too. [ruby-dev:32093]
+
Sun Jun 8 01:51:52 2008 James Edward Gray II <jeg2@r...>
Merged 13767, 13768, 13769, and 13770 from trunk.
Index: ruby_1_8_5/version.h
===================================================================
--- ruby_1_8_5/version.h (revision 16908)
+++ ruby_1_8_5/version.h (revision 16909)
@@ -2,7 +2,7 @@
#define RUBY_RELEASE_DATE "2008-06-08"
#define RUBY_VERSION_CODE 185
#define RUBY_RELEASE_CODE 20080608
-#define RUBY_PATCHLEVEL 137
+#define RUBY_PATCHLEVEL 138
#define RUBY_VERSION_MAJOR 1
#define RUBY_VERSION_MINOR 8
Index: ruby_1_8_5/io.c
===================================================================
--- ruby_1_8_5/io.c (revision 16908)
+++ ruby_1_8_5/io.c (revision 16909)
@@ -245,6 +245,7 @@
if (fptr->mode & FMODE_WBUF) {
io_fflush(GetWriteFile(fptr), fptr);
}
+ errno = 0;
return fptr;
}
@@ -668,7 +669,7 @@
GetOpenFile(io, fptr);
pos = io_tell(fptr);
- if (pos < 0) rb_sys_fail(fptr->path);
+ if (pos < 0 && errno) rb_sys_fail(fptr->path);
return OFFT2NUM(pos);
}
@@ -683,7 +684,7 @@
pos = NUM2OFFT(offset);
GetOpenFile(io, fptr);
pos = io_seek(fptr, pos, whence);
- if (pos < 0) rb_sys_fail(fptr->path);
+ if (pos < 0 && errno) rb_sys_fail(fptr->path);
clearerr(fptr->f);
return INT2FIX(0);
--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/