diff options
| author | Yukihiro "Matz" Matsumoto <[email protected]> | 2015-02-27 17:14:32 +0900 |
|---|---|---|
| committer | Yukihiro "Matz" Matsumoto <[email protected]> | 2015-02-27 17:14:32 +0900 |
| commit | 3cba7016723b6817f77771d9e5abe7da82f74f7d (patch) | |
| tree | 7e8105c03e507c3fa709576c8c7c9deaa70a3a10 /src/fmt_fp.c | |
| parent | 3df32161797aa9c6e9df259e8d8571b454cb2333 (diff) | |
| download | mruby-3cba7016723b6817f77771d9e5abe7da82f74f7d.tar.gz mruby-3cba7016723b6817f77771d9e5abe7da82f74f7d.zip | |
fix MSVC initialization issue by a patch from @dyama; close #2734
Diffstat (limited to 'src/fmt_fp.c')
| -rw-r--r-- | src/fmt_fp.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/fmt_fp.c b/src/fmt_fp.c index 451d691d8..cfbda570a 100644 --- a/src/fmt_fp.c +++ b/src/fmt_fp.c @@ -360,7 +360,10 @@ fmt_core(struct fmt_args *f, const char *fmt, mrb_float flo) mrb_value mrb_float_to_str(mrb_state *mrb, mrb_value flo, const char *fmt) { - struct fmt_args f = { mrb, mrb_str_buf_new(mrb, 24) }; + struct fmt_args f; + + f.mrb = mrb; + f.str = mrb_str_buf_new(mrb, 24); if (fmt_core(&f, fmt, mrb_float(flo)) < 0) { mrb_raise(mrb, E_ARGUMENT_ERROR, "invalid format string"); } |
