summaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authorTomoyuki Sahara <[email protected]>2017-06-12 15:43:44 +0900
committerGitHub <[email protected]>2017-06-12 15:43:44 +0900
commit0b41066e83ace09f57f6e42cbd78b931f30a0307 (patch)
tree97d5ac017100368221c436c906011b79578d44fc /src
parent3a73a5849388fe908af7131804f9fc7f55472651 (diff)
parent27f422880fa501a16642e0499b8140c074b5269b (diff)
downloadmruby-0b41066e83ace09f57f6e42cbd78b931f30a0307.tar.gz
mruby-0b41066e83ace09f57f6e42cbd78b931f30a0307.zip
Merge pull request #84 from ksss/pos
To accurate `pos`
Diffstat (limited to 'src')
-rw-r--r--src/io.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/src/io.c b/src/io.c
index e0de0ca36..992801a62 100644
--- a/src/io.c
+++ b/src/io.c
@@ -389,7 +389,6 @@ mrb_io_s_popen(mrb_state *mrb, mrb_value klass)
}
mrb_iv_set(mrb, io, mrb_intern_cstr(mrb, "@buf"), mrb_str_new_cstr(mrb, ""));
- mrb_iv_set(mrb, io, mrb_intern_cstr(mrb, "@pos"), mrb_fixnum_value(0));
fptr = mrb_io_alloc(mrb);
fptr->fd = fd;
@@ -443,7 +442,6 @@ mrb_io_initialize(mrb_state *mrb, mrb_value io)
flags = mrb_io_modestr_to_flags(mrb, mrb_string_value_cstr(mrb, &mode));
mrb_iv_set(mrb, io, mrb_intern_cstr(mrb, "@buf"), mrb_str_new_cstr(mrb, ""));
- mrb_iv_set(mrb, io, mrb_intern_cstr(mrb, "@pos"), mrb_fixnum_value(0));
fptr = (struct mrb_io *)DATA_PTR(io);
if (fptr != NULL) {
@@ -801,7 +799,6 @@ mrb_io_s_pipe(mrb_state *mrb, mrb_value klass)
r = mrb_obj_value(mrb_data_object_alloc(mrb, mrb_class_ptr(klass), NULL, &mrb_io_type));
mrb_iv_set(mrb, r, mrb_intern_cstr(mrb, "@buf"), mrb_str_new_cstr(mrb, ""));
- mrb_iv_set(mrb, r, mrb_intern_cstr(mrb, "@pos"), mrb_fixnum_value(0));
fptr_r = mrb_io_alloc(mrb);
fptr_r->fd = pipes[0];
fptr_r->readable = 1;
@@ -812,7 +809,6 @@ mrb_io_s_pipe(mrb_state *mrb, mrb_value klass)
w = mrb_obj_value(mrb_data_object_alloc(mrb, mrb_class_ptr(klass), NULL, &mrb_io_type));
mrb_iv_set(mrb, w, mrb_intern_cstr(mrb, "@buf"), mrb_str_new_cstr(mrb, ""));
- mrb_iv_set(mrb, w, mrb_intern_cstr(mrb, "@pos"), mrb_fixnum_value(0));
fptr_w = mrb_io_alloc(mrb);
fptr_w->fd = pipes[1];
fptr_w->readable = 0;