summaryrefslogtreecommitdiffhomepage
AgeCommit message (Collapse)Author
2020-02-12Fix integer boundary check before `float` to `time_t` casting.Yukihiro "Matz" Matsumoto
2020-02-05Merge pull request #4941 from davidsiaw/mac-compatYukihiro "Matz" Matsumoto
Include time.h for ios
2020-02-03Add explicit type cast to return value from `mrmchr`; ref #4940Yukihiro "Matz" Matsumoto
C++ is stricter in implicit type casting.
2020-02-03Use simple search for short strings in `mrb_memsearch_qs`; close #4940Yukihiro "Matz" Matsumoto
Differences from the PR #4940: * Use simple search for short strings only. * "short" means `m+n` is shorter than `MRB_QS_SHORT_STRING_LENGTH`. * The current default value for `MRB_QS_SHORT_STRING_LENGTH` is 2048.
2020-02-02Implement `IO#pread` and `IO#pwrite`dearblue
It is available by default in environments where `__unix__` is defined. Other environments are enabled by defining `MRB_WITH_IO_PREAD_PWRITE` (requires an implementation of `pread()` and `pwrite()` functions). In any case, you can disable it by defining `MRB_WITHOUT_IO_PREAD_PWRITE`.
2020-02-01Merge pull request #4938 from dearblue/socket-mingwYukihiro "Matz" Matsumoto
Fix builds for old mingw in mruby-socket; ref #4914
2020-02-01Fix builds for old mingw in mruby-socket; ref #4914dearblue
2020-01-31Add explicit casting in `file.c` to silence warnings.Yukihiro "Matz" Matsumoto
2020-01-31Avoid casting warning from `mrb_int` to `int` in `io.c`.Yukihiro "Matz" Matsumoto
2020-01-31Avoid implicit integer casting in `backtrace.c` and `hash.c`.Yukihiro "Matz" Matsumoto
2020-01-31Remove unnecessary use of `uint16_t` in `symbol.c`.Yukihiro "Matz" Matsumoto
2020-01-30Fix arena index type from `mrb_int` to just `int`.Yukihiro "Matz" Matsumoto
2020-01-30Move fallback definitions of `FLT_EPSILON` etc. after `#include <mruby/value.h>`Yukihiro "Matz" Matsumoto
that includes `float.h`. It allows definitions from native headers.
2020-01-29Removed junk.Yukihiro "Matz" Matsumoto
My cat stepped on the keyboard at the last moment before the commit.
2020-01-29Remove unused local variable `mid`; ref #4936Yukihiro "Matz" Matsumoto
2020-01-28Merge pull request #4873 from dearblue/open-flagsYukihiro "Matz" Matsumoto
Support bit flags for `IO.open`
2020-01-28include time.h for iosDavid Siaw
2020-01-27Fixed backtrace message for top-level blocks; fix #4936Yukihiro "Matz" Matsumoto
In top-level, `mid` is `NULL`. We used to ignore 'mid` update for `NULL`.
2020-01-21Merge pull request #4935 from mimaki/delete-duplicated-Array-delete_ifYukihiro "Matz" Matsumoto
Delete duplicated `Array#delete_if`.
2020-01-21Delete duplicated `Array#delete_if` test.Hiroshi Mimaki
2020-01-21Delete duplicated `Array#delete_if`.Hiroshi Mimaki
2020-01-15Remove `debug` target from `travis_config.rb`.Yukihiro "Matz" Matsumoto
2020-01-15Remove broken `MRB_INT16` configuration option.Yukihiro "Matz" Matsumoto
2020-01-10Fixed wrong condition in #4926 fix.Yukihiro "Matz" Matsumoto
2020-01-10Fixed wrong condition for copying arguments on stack; fix #4926Yukihiro "Matz" Matsumoto
This bug was introduced in 694089f to address #4832
2020-01-10Small refactoring in `hash_slice`; ref #4926Yukihiro "Matz" Matsumoto
2020-01-08Add `MRB_WITHOUT_FLOAT` guard to `<math.h>`.Yukihiro "Matz" Matsumoto
2020-01-08Fix buffer overflow in `mrb_str_len_to_dbl`.Yukihiro "Matz" Matsumoto
Issue 19902: mruby:mruby_fuzzer: Stack-buffer-overflow in mrb_str_len_to_dbl
2020-01-08`p->locals` may be `NULL` when error occurs before the point.Yukihiro "Matz" Matsumoto
This is reported by oss-fuzz: Issue 19886: mruby:mruby_fuzzer: Potential-null-reference in setup_numparams
2020-01-07Check memory boundary in `mrb_str_len_to_dbl`.Yukihiro "Matz" Matsumoto
2020-01-06`"0x10".to_f` should be `0`, not `16.0`; fix #4924Yukihiro "Matz" Matsumoto
2020-01-06Check remaining string length before access to avoid OOB access.Yukihiro "Matz" Matsumoto
2020-01-06Need to preserve the original input string in `mrb_str_len_to_dbl`.Yukihiro "Matz" Matsumoto
2020-01-06Merge branch 'dearblue-file-size-truncate'Yukihiro "Matz" Matsumoto
2020-01-06Avoid Boxing/Unboxing of file descriptors; ref #4872Yukihiro "Matz" Matsumoto
2020-01-06Merge branch 'file-size-truncate' of https://github.com/dearblue/mruby into ↵Yukihiro "Matz" Matsumoto
dearblue-file-size-truncate
2020-01-06Fix `mrb_str_len_to_dbl` to support Hexadecimal like `0x10`.Yukihiro "Matz" Matsumoto
2020-01-06Refactor `mrb_cstr_to_dbl`; ref #4920Yukihiro "Matz" Matsumoto
2020-01-06Avoid creating temporary objects in `read_irep_record_1`; close #4920Yukihiro "Matz" Matsumoto
The basic idea of this change is from @dearblue. Note: the arguments of `mrb_str_pool()` have changed, but the function is provided for internal use (No `MRB_API`). So basically you don't have to worry about the change.
2020-01-05Merge pull request #4923 from dearblue/kwargs-blockYukihiro "Matz" Matsumoto
Fix ainfo with keyword arguments; fix #4921
2020-01-05Fix ainfo with keyword arguments; fix #4921dearblue
2020-01-02Merge pull request #4917 from dearblue/va_endYukihiro "Matz" Matsumoto
Call `va_end()` before return
2020-01-02Call `va_end()` before returndearblue
The behavior when returning from a function without `va_end()` is undefined.
2020-01-01Rename `mrb_num_args_error` to `mrb_argnum_error`; ref #4863Yukihiro "Matz" Matsumoto
2020-01-01Merge pull request #4863 from ↵Yukihiro "Matz" Matsumoto
shuujii/add-mrb_num_args_error-for-wrong-number-of-arguments-error Add `mrb_num_args_error()` for "wrong number of arguments" error
2020-01-01Merge pull request #4919 from ↵Yukihiro "Matz" Matsumoto
shuujii/revert-SHARED-string-is-not-required-when-sharing-POOL-string Revert "SHARED string is not required when sharing POOL string" (75949836)
2020-01-01Revert "SHARED string is not required when sharing POOL string" (75949836)KOBAYASHI Shuji
Because literal pool may be released by GC. #### Example: ```ruby s1 = eval('"abcdefghijklmnopqrstuvwxyz01"') GC.start p s1 #=> "\x00\x00\x00\x00\x00\x00\x00\x90\x00\x00\x00\x00\x00\x00\x00\x90\x03\x00stuvwxyz01" ```
2020-01-01Merge pull request #4918 from dearblue/sync-varsYukihiro "Matz" Matsumoto
Integrate `i` and `arg_i` in `mrb_get_args()`
2020-01-01Merge pull request #4916 from dearblue/stdintYukihiro "Matz" Matsumoto
Do not include `stdint.h` before `mruby.h`; ref #4750
2020-01-01Integrate `i` and `arg_i` in `mrb_get_args()`dearblue
The behavior of these two variables is the same.