diff options
| author | Paolo Bosetti <[email protected]> | 2012-05-29 14:32:05 -0700 |
|---|---|---|
| committer | Paolo Bosetti <[email protected]> | 2012-05-29 14:32:05 -0700 |
| commit | d73517877847dab5b345c7fa98091647737bbfe0 (patch) | |
| tree | 6090a2df49b8093606181e5416e6aa6a5040b0ec /src/string.c | |
| parent | 391f8dcef02cdafeb4e0acc693945acb166a8d09 (diff) | |
| parent | 1e5d15dbcb977f6d197c24eca4a973ee1c5bf521 (diff) | |
| download | mruby-d73517877847dab5b345c7fa98091647737bbfe0.tar.gz mruby-d73517877847dab5b345c7fa98091647737bbfe0.zip | |
Merge branch 'master' of git://github.com/mruby/mruby into XCode
Diffstat (limited to 'src/string.c')
| -rw-r--r-- | src/string.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/string.c b/src/string.c index 28513c15c..695b0d01c 100644 --- a/src/string.c +++ b/src/string.c @@ -4400,9 +4400,17 @@ mrb_str_conv_enc_opts(mrb_state *mrb, mrb_value str, mrb_encoding *from, mrb_enc mrb_enc_associate(mrb, newstr, to); return newstr; - default: + case econv_invalid_byte_sequence: + case econv_undefined_conversion: + case econv_source_buffer_empty: + case econv_after_output: + case econv_incomplete_input: /* some error, return original */ return str; + + default: + mrb_bug("Internal Error: Invalid return value mrb_econv_convert."); + return str; } } |
