aboutsummaryrefslogtreecommitdiffstats
path: root/ext
Commit message (Collapse)AuthorAgeFilesLines
* [ruby/digest] Suppress implicit cast down warningsNobuyoshi Nakada2023-11-091-1/+2
| | | | https://github.com/ruby/digest/commit/2f3505bf3f
* [ruby/stringio] Development of 3.1.0 started.Sutou Kouhei2023-11-081-1/+1
| | | | https://github.com/ruby/stringio/commit/a2f8ef1a6a
* [ruby/stringio] Add missing row separator encoding conversionSutou Kouhei2023-11-081-22/+41
| | | | | | | | | | | | | (https://github.com/ruby/stringio/pull/69) The conversion logic is borrowed from ruby/ruby's io.c: https://github.com/ruby/ruby/blob/40391faeab608665da87a05c686c074f91a5a206/io.c#L4059-L4079 Fix ruby/stringio#68 Reported by IWAMOTO Kouichi. Thanks!!! https://github.com/ruby/stringio/commit/4b170c1a68
* [ruby/strscan] Bump versionSutou Kouhei2023-11-081-1/+1
| | | | https://github.com/ruby/strscan/commit/1b3393be05
* [ruby/fiddle] Remove garbageSutou Kouhei2023-11-081-1/+0
| | | | https://github.com/ruby/fiddle/commit/bbcb66e16e
* [ruby/fiddle] Include stdbool.h explicitly for old RubySutou Kouhei2023-11-081-0/+1
| | | | https://github.com/ruby/fiddle/commit/74a05fb358
* [ruby/fiddle] Use Ruby's true/false for C boolSutou Kouhei2023-11-087-22/+89
| | | | | | | | GitHub: fix https://github.com/ruby/fiddle/pull/130 Reported by Benoit Daloze. Thanks!!! https://github.com/ruby/fiddle/commit/2640e0148e
* [flori/json] Enhanced RDoc for Range extensionsBurdetteLamar2023-11-081-7/+22
| | | | https://github.com/flori/json/commit/ec47749b53
* String for string literal is not resizableNobuyoshi Nakada2023-11-082-0/+13
|
* [ruby/cgi] Add snake case aliases for escapeURIComponentJean Boussier2023-11-071-0/+2
| | | | | | As agreed in [Feature #18822] https://github.com/ruby/cgi/commit/9d1161ec9d
* [ruby/zlib] Bump up 3.1.0Hiroshi SHIBATA2023-11-071-1/+1
| | | | https://github.com/ruby/zlib/commit/2561e122ac
* [ruby/zlib] Support Ruby 2.5+ againHiroshi SHIBATA2023-11-071-1/+1
| | | | https://github.com/ruby/zlib/commit/661ea3ec5f
* [ruby/pathname] Bump up 0.3.0Hiroshi SHIBATA2023-11-071-1/+1
| | | | https://github.com/ruby/pathname/commit/f3d23679b0
* [ruby/fcntl] Bump up 1.1.0Hiroshi SHIBATA2023-11-071-1/+1
| | | | https://github.com/ruby/fcntl/commit/fe780abe07
* [ruby/win32ole] Bump up 1.8.10Hiroshi SHIBATA2023-11-071-1/+1
| | | | https://github.com/ruby/win32ole/commit/9a18f388a9
* [ruby/bigdecimal] fixed docs for .scaleTim Kretschmer2023-11-071-1/+1
| | | | | | the scale of `1` is actually 0 https://github.com/ruby/bigdecimal/commit/9a8bc9c417
* [ruby/bigdecimal] Update doc for bigdecimal/utilKoichi ITO2023-11-071-5/+5
| | | | | | | | | | | | | Follow up https://github.com/ruby/bigdecimal/issues/89. `BigDecimal.new` has already been removed. This PR replaces `BigDecimal.new` with `Kernel.BigDecimal` in the documentation, following the message below: > BigDecimal.new is deprecated; use Kernel.BigDecimal method instead. https://github.com/ruby/bigdecimal/commit/26d84ba766e971da8eaaf2ce41e7b89935fa68da https://github.com/ruby/bigdecimal/commit/dd52adf3b2
* [ruby/date] Bump up 3.3.4Hiroshi SHIBATA2023-11-071-1/+1
| | | | https://github.com/ruby/date/commit/50e18d2684
* Prevent cpu_set_t overflow even if there are more than 63 coresYusuke Endoh2023-11-071-4/+10
| | | | | Do not use `pthread_attr_setaffinity_np` if `sched_getcpu()` exceeds `CPU_SETSIZE`. (Using `CPU_ALLOC()` would be more appropriate.)
* Fix a memory leakYusuke Endoh2023-11-071-1/+1
| | | | pointed by @nobu
* Use pthread_attr_setaffinity_np instead of pthread_setaffinity_npYusuke Endoh2023-11-072-11/+21
|
* Detach a pthread after pthread_setaffinity_npYusuke Endoh2023-11-071-2/+2
| | | | | | | | | | After a pthread for getaddrinfo is detached, we cannot predict when the thread will exit. It would lead to a segfault by setting pthread_setaffinity to the terminated pthread. I guess this problem would be more likely to occur in high-load environments. This change detaches the pthread after pthread_setaffinity is called. [Feature #19965]
* Revert "Do not use pthread_setaffinity_np on s390x"Yusuke Endoh2023-11-071-5/+2
| | | | This reverts commit de82439215dd2770ef9a3a2cf5798bdadb788533.
* [ruby/etc] Fix inconsistent dll linkage warningNobuyoshi Nakada2023-11-051-1/+1
| | | | https://github.com/ruby/etc/commit/e4c71e5996
* [ruby/stringio] Make STRINGIO_VERSION uniformNobuyoshi Nakada2023-11-042-2/+3
| | | | https://github.com/ruby/stringio/commit/4400bf3380
* [ruby/stringio] Move Java version to Java directoryNobuyoshi Nakada2023-11-041-1/+2
| | | | https://github.com/ruby/stringio/commit/3f90a0d619
* Make every initial size pool shape a root shapePeter Zhu2023-11-021-5/+0
| | | | | This commit makes every initial size pool shape a root shape and assigns it a capacity of 0.
* [Feature #10602] Add new API rb_profile_thread_frames()Daisuke Aritomo2023-10-311-0/+21
| | | | | | | | | | | | | | | | | | | | Add a new API rb_profile_thread_frames(), which is essentialy a per-thread version of rb_profile_frames(). While the original rb_profile_frames() always returns results about the current active thread obtained by GET_EC(), this new API takes a Thread to be profiled as an argument. This should come in handy when profiling I/O-bound programs such as webapps, since this new API allows us to learn about Threads performing I/O (which do not have the GVL). Profiling worker threads (such as Sidekiq workers) may be another application. Implements [Feature #10602] Co-authored-by: Mike Perham <mike@perham.net>
* [ruby/etc] Start 1.4.3Nobuyoshi Nakada2023-10-291-1/+1
| | | | https://github.com/ruby/etc/commit/a9e4d4730d
* [ruby/zlib] Check for z_size_t along with {crc,adler}32_z inKJ Tsanaktsidis2023-10-261-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | extconf.rb (https://github.com/ruby/zlib/pull/69) The android NDK (android-ndk-r21e) does not have crc32_z, adler32_z, nor z_size_t in its zlib.h header file. However, it _does_ have the crc32_z and adler32_z symbols in the libz.a static library! mkmf performs two tests for have_func: * It sees if a program that includes the header and takes the address of the symbol can compile * It sees if a program that defines the symbol as `extern void sym_name()` and calls it can be linked If either test works, it considers the function present. The android-ndk-r21e is passing the second test but not the first for crc32_z/adler32_z. So, we define HAVE_ZLIB_SIZE_T_FUNCS, but then can't actually compile the extension (since the prototypes aren't in the header file). We can keep this working how it was working before by _also_ checking for `have_type("z_size_t", "zlib.h")`. The have_type check _only_ looks in the header file for the type; if a program including the header file and using the type can't compile, the type is considered absent regardless of what might be in libz.a. https://github.com/ruby/zlib/commit/3b9fe962d8
* [ruby/zlib] Fix misdetection of {crc32,alder32}_z in cloudflare zlib forkKJ Tsanaktsidis2023-10-262-4/+8
| | | | | | | | | | | | | | | | | | | | | | We use the Cloudflare fork of zlib (https://github.com/cloudflare/zlib), which we find gives improved performance on AWS Graviton ARM instances. That fork does not define crc32_z and alder32_z functions. Until two days ago, Ruby's zlib gem worked fine, because cloudflare zlib _also_ did not define z_size_t, which meant Ruby did not try and use these functions. Since https://github.com/cloudflare/zlib/commit/a3ba99596d6271224d39ef9d6853511f51821e05 however, cloudflare zlib _does_ define z_size_t (but NOT crc32_z or alder32_z). The zlib gem would try and use these nonexistant functions and not compile. This patch fixes it by actually specifically detecting the functions that the gem wants to call, rather than just the presence of the z_size_t type. https://github.com/ruby/zlib/commit/c96e8b9a57
* Do not use pthread_setaffinity_np on s390xYusuke Endoh2023-10-251-2/+5
| | | | | | | | | | Looks like it randomly causes a segfault https://rubyci.s3.amazonaws.com/rhel_zlinux/ruby-master/log/20231025T093302Z.fail.html.gz ``` [11186/26148] TestNetHTTP_v1_2#test_set_form/home/chkbuild/build/20231025T093302Z/ruby/tool/lib/webrick/httprequest.rb:197: [BUG] Segmentation fault at 0x000003ff1ffff000 ruby 3.3.0dev (2023-10-25T07:50:00Z master 526292d9fe) [s390x-linux] ```
* rb_getaddrinfo should return EAI_AGAIN instead of EAGAINYusuke Endoh2023-10-241-6/+6
|
* Indent critical regions with blocksYusuke Endoh2023-10-241-23/+29
| | | | Cosmetic change per ko1's preference
* Do not use pthread on mingwYusuke Endoh2023-10-241-1/+1
|
* Make rb_getnameinfo interruptibleYusuke Endoh2023-10-241-1/+169
| | | | Same as previous commit for rb_getnameinfo.
* Make rb_getaddrinfo interruptibleYusuke Endoh2023-10-242-2/+191
| | | | | | | | When pthread_create is available, rb_getaddrinfo creates a pthread and executes getaddrinfo(3) in it. The caller thread waits for the pthread to complete, but detaches it if interrupted. This allows name resolution to be interuppted by Timeout.timeout, etc. even if it takes a long time (for example, when the DNS server does not respond). [Feature #19965]
* Expand macro branches to make them plainYusuke Endoh2023-10-241-37/+50
|
* Refactor GETADDRINFO_IMPL instead of GETADDRINFO_EMUYusuke Endoh2023-10-241-4/+15
| | | | | This is a preparation for introducing cancellable getaddrinfo/getnameinfo.
* refactor a call to getaddrinfoYusuke Endoh2023-10-241-11/+17
|
* [ruby/io-nonblock] Don't define nonblock methods if they are defined by core.Samuel Williams2023-10-231-0/+7
| | | | https://github.com/ruby/io-nonblock/commit/5d3991859c
* [ruby/io-console] Intersperse Win32 and termios implementationsNobuyoshi Nakada2023-10-221-141/+124
| | | | | | So that the both sources appear in RDoc generated HTMLs. https://github.com/ruby/io-console/commit/beec164a47
* [ruby/io-console] Start 0.6.1Nobuyoshi Nakada2023-10-221-1/+1
| | | | https://github.com/ruby/io-console/commit/06307a755d
* [ruby/io-console] [DOC] Split .document files to sync with ruby/rubyNobuyoshi Nakada2023-10-222-2/+3
| | | | https://github.com/ruby/io-console/commit/13e0bcac9f
* [ruby/io-console] [DOC] Add .documentNobuyoshi Nakada2023-10-211-0/+1
| | | | https://github.com/ruby/io-console/commit/62a677b51a
* Stop creating ripper.h because it's not usedyui-knk2023-10-202-2/+2
|
* Use rb_getnameinfo instead of directly using getnameinfoYusuke Endoh2023-10-171-9/+9
|
* [ruby/psych] Bump up v5.1.1.1Hiroshi SHIBATA2023-10-161-1/+1
| | | | https://github.com/ruby/psych/commit/51cc86ff3f
* Switch mid dump to dump_append_string_valueJohn Hawthorn2023-10-121-3/+2
| | | | | | I don't think it's possible to create a CI with a mid which would need escaping to be in a JSON string, but I think we might as well not rely on that assumption.
* Fix ObjectSpace.dump with super() callinfoJohn Hawthorn2023-10-121-3/+7
| | | | | super() uses 0 as mid for its callinfo, so we need to check for that to avoid a segfault when using dump_all.