diff options
| author | Tomoyuki Sahara <[email protected]> | 2015-12-03 12:22:59 +0900 |
|---|---|---|
| committer | Tomoyuki Sahara <[email protected]> | 2015-12-03 12:22:59 +0900 |
| commit | 6c67120ed4d6971f40a307dd8e63e0f6a48fb839 (patch) | |
| tree | f959af83ec3d729b2632e93d5955d8e7908a3a75 | |
| parent | 7337bfa4973a7d17676f160f41dd60f9ae5c3094 (diff) | |
| parent | b19c315148cfda6d02b4073b4f741d2e4d5e96a7 (diff) | |
| download | mruby-6c67120ed4d6971f40a307dd8e63e0f6a48fb839.tar.gz mruby-6c67120ed4d6971f40a307dd8e63e0f6a48fb839.zip | |
Merge pull request #54 from takahashim/win-crlf
fix tests for Win: use binary mode
| -rw-r--r-- | test/mruby_io_test.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/mruby_io_test.c b/test/mruby_io_test.c index 98ec54524..2777e605e 100644 --- a/test/mruby_io_test.c +++ b/test/mruby_io_test.c @@ -53,7 +53,7 @@ mrb_io_test_io_setup(mrb_state *mrb, mrb_value self) mrb_gv_set(mrb, mrb_intern_cstr(mrb, "$mrbtest_io_socketname"), mrb_str_new_cstr(mrb, socketname)); mrb_gv_set(mrb, mrb_intern_cstr(mrb, "$mrbtest_io_msg"), mrb_str_new_cstr(mrb, msg)); - fp = fopen(rfname, "w"); + fp = fopen(rfname, "wb"); if (fp == NULL) { mrb_raise(mrb, E_RUNTIME_ERROR, "can't open temporary file"); return mrb_nil_value(); @@ -61,7 +61,7 @@ mrb_io_test_io_setup(mrb_state *mrb, mrb_value self) fputs(msg, fp); fclose(fp); - fp = fopen(wfname, "w"); + fp = fopen(wfname, "wb"); if (fp == NULL) { mrb_raise(mrb, E_RUNTIME_ERROR, "can't open temporary file"); return mrb_nil_value(); |
