diff options
| author | Paolo Bosetti <[email protected]> | 2012-05-30 22:10:02 -0700 |
|---|---|---|
| committer | Paolo Bosetti <[email protected]> | 2012-05-30 22:10:02 -0700 |
| commit | 6dbba7b799e0cf1a86ec86f347bbc1b40420d372 (patch) | |
| tree | ebbc4d9d1a526833fde0819bcd9a1124be656540 /src/error.c | |
| parent | 1da34f46f4ff4ddff8f5c525aab13fdfd7eb4a99 (diff) | |
| parent | fae483ff2a91e806e714cb7d118c7bfb8aadbeb2 (diff) | |
| download | mruby-6dbba7b799e0cf1a86ec86f347bbc1b40420d372.tar.gz mruby-6dbba7b799e0cf1a86ec86f347bbc1b40420d372.zip | |
Merge branch 'master' of git://github.com/mruby/mruby into XCode
Diffstat (limited to 'src/error.c')
| -rw-r--r-- | src/error.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/error.c b/src/error.c index feaa04af7..ae89541c1 100644 --- a/src/error.c +++ b/src/error.c @@ -56,9 +56,9 @@ exc_initialize(mrb_state *mrb, mrb_value exc) { mrb_value mesg; - mrb_get_args(mrb, "o", &mesg); - mrb_iv_set(mrb, exc, mrb_intern(mrb, "mesg"), mesg); - + if (mrb_get_args(mrb, "|o", &mesg) == 1) { + mrb_iv_set(mrb, exc, mrb_intern(mrb, "mesg"), mesg); + } return exc; } |
