| Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Alias init functions
The extension library has each initialization function named "Init_" +
basename. If multiple extensions have the same base name (such as
cgi/escape and erb/escape), the same function will be registered for
both names.
To fix this conflict, rename the initialization functions under sub
directories using using parent names, when statically linking.
---
ext/extmk.rb | 16 +++++++++++++++-
template/extinit.c.tmpl | 2 +-
2 files changed, 16 insertions(+), 2 deletions(-)
|
|
Refer autoconfigured endian macro (#10572)
Remove the case `RB_IO_BUFFER_HOST_ENDIAN` is not defined.
---
include/ruby/io/buffer.h | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
|
|
Check if macros are defined before using
Assume macros with the same prefix would be defined together.
---
include/ruby/io/buffer.h | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
|
|
tool/runruby.rb: remove LD_PRELOAD-like env-var options from
runruby.rb
LD_PRELOAD sometimes forces loading libraries into unrelated
executables. For example, macOS on recent Apple Silicon can execute
arm64 and arm64e binaries by default, and /usr/bin/clang is built as
arm64e. If Ruby is built as arm64, and mkmf launched through runruby.rb
spawns /usr/bin/clang, dynamic loader tries to load libruby (arm64e)
into clang (arm64). This force-load causes library load failure.
In theory, we don't need both LD_PRELOAD and LD_LIBRARY_PATH at the same
time, because executables requiring libruby already have libruby
dependency, so LD_LIBRARY_PATH is enough for this case.
---
tool/runruby.rb | 9 ---------
1 file changed, 9 deletions(-)
|
|
|
|
Include headers for `ruby_qsort` only if needed
If GNU `qsort_r` is available, we use the function and these headers
are not used.
---
util.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
Delete a macro that has never been used, probably added by mistake
---
util.c | 7 -------
1 file changed, 7 deletions(-)
|
|
[Bug #18997] Don't define ruby_qsort when POSIX qsort_r is available
The current code would define ruby_qsort as a wrapper of qsort_s
when it is available. When both qsort_s and POSIX (GNU) qsort_r
are available, we should call qsort_r directly instead, and
the qsort_s wrapper is redundant.
---
util.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
|
|
|
|
|
|
Fix Use-After-Free issue for Regexp
Co-authored-by: Isaac Peka <7493006+isaac-peka@users.noreply.github.com>
---
regexec.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
Fix handling of reg->dmin in Regex matching
---
regexec.c | 10 ++++++++++
1 file changed, 10 insertions(+)
|
|
|
|
|
|
|
|
|
|
[Bug #19969] Compact st_table after deleted if possible
---
hash.c | 19 +++++++++++++++++++
st.c | 40 +++++++++++++++++++++++++++++-----------
test/ruby/test_hash.rb | 9 +++++++++
3 files changed, 57 insertions(+), 11 deletions(-)
|
|
|
|
|
|
At the time this test first started using `assert_raise_with_message`,
it did not touch `Encoding.default_internal`.
|
|
[Bug #19985] Raise LoadError with the converted feature name
`Kernel#require` converts feature name objects that have the `to_path`
method such as `Pathname`, but had used the original object on error
and had resulted in an unexpected `TypeError`.
---
load.c | 14 +++++++++++---
test/ruby/test_require.rb | 26 +++++++++++++++++++++-----
2 files changed, 32 insertions(+), 8 deletions(-)
|
|
[Bug #19754] Make `IO::Buffer#get_string` check `offset` range
(#8016)
---
io_buffer.c | 3 +++
test/ruby/test_io_buffer.rb | 8 ++++++++
2 files changed, 11 insertions(+)
|
|
Fix false LocalJumpError when branch coverage is enabled
`throw TAG_BREAK` instruction makes a jump only if the continuation of
catch of TAG_BREAK exactly matches the instruction immediately following
the "send" instruction that is currently being executed. Otherwise, it
seems to determine break from proc-closure.
Branch coverage may insert some recording instructions after "send"
instruction, which broke the conditions for TAG_BREAK to work properly.
This change forces to set the continuation of catch of TAG_BREAK
immediately after "send" (or "invokesuper") instruction.
[Bug #18991]
---
compile.c | 25 ++++++++++++++++++++++++-
test/coverage/test_coverage.rb | 14 ++++++++++++++
2 files changed, 38 insertions(+), 1 deletion(-)
|
|
|
|
bcb3247072e6973d0f6b50ca5fed238d5824bd28,fe0225ff4d5af8b1f54009727b39d0d9b821eea3: [Backport #19778]
[Bug #19778] Pass additional include options to INCFLAGS in common.mk
---
common.mk | 2 +-
configure.ac | 1 +
template/Makefile.in | 1 +
3 files changed, 3 insertions(+), 1 deletion(-)
[Bug #19778] Add `-I` options for opt-dir to `$INCFLAGS`
These options have been separated from `$CFLAGS` already in the
other places.
---
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
Fix memory leak in complemented method entries
[Bug #19894]
When a copy of a complemented method entry is created, there are two
issues:
1. IMEMO_FL_USER3 is not copied, so the complemented status is not
copied over.
2. In rb_method_entry_clone we increment both alias_count and
complemented_count. However, when we free the method entry in
rb_method_definition_release, we only decrement one of the two
counters, resulting in the rb_method_definition_t being leaked.
Co-authored-by: Adam Hess <adamhess1991@gmail.com>
---
method.h | 5 +++--
test/ruby/test_module.rb | 29 +++++++++++++++++++++++++++++
vm_method.c | 8 +++++---
3 files changed, 37 insertions(+), 5 deletions(-)
|
|
[ruby/fiddle] closure: follow variable name change
GitHub: GH-102
https://github.com/ruby/fiddle/commit/2530496602
---
ext/fiddle/closure.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
See 1b0da1e6236ad9a380abfe4ca8b51f06c34bb6f9
|
|
Fix Array#bsearch when block returns a non-integer numeric value
---
array.c | 4 ++--
test/ruby/test_array.rb | 4 ++++
2 files changed, 6 insertions(+), 2 deletions(-)
|
|
|