diff options
| author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-02-28 12:32:39 +0000 |
|---|---|---|
| committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-02-28 12:32:39 +0000 |
| commit | 1a5a2bae57d89cd1c74395dcb7f28c84ebf97a3c (patch) | |
| tree | f128df8fd6edf1fbd57105cb9cf18ed15c81f318 | |
| parent | 82a828a35d6d6d49a78b2753a9cc315f1332a129 (diff) | |
* ext/pty/pty.c (get_device_once): raise on error when fail is
non-zero.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@26786 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
| -rw-r--r-- | ChangeLog | 5 | ||||
| -rw-r--r-- | ext/pty/pty.c | 2 |
2 files changed, 6 insertions, 1 deletions
@@ -1,3 +1,8 @@ +Sun Feb 28 21:32:36 2010 Nobuyoshi Nakada <nobu@ruby-lang.org> + + * ext/pty/pty.c (get_device_once): raise on error when fail is + non-zero. + Sun Feb 28 15:12:37 2010 Nobuyoshi Nakada <nobu@ruby-lang.org> * lib/open3.rb (Open3#popen3): ignore trap and at_exit also when diff --git a/ext/pty/pty.c b/ext/pty/pty.c index 8d2b483595..80eff8bb21 100644 --- a/ext/pty/pty.c +++ b/ext/pty/pty.c @@ -369,7 +369,7 @@ get_device_once(master, slave, SlaveName, fail) } close(i); } - if (!fail) rb_raise(rb_eRuntimeError, "can't get Master/Slave device"); + if (fail) rb_raise(rb_eRuntimeError, "can't get Master/Slave device"); return -1; #else const char *const *p; |
