Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ruby: Fix build failures with Ruby 3.4
Ruby 3.4 started to actually mark some deprecated functions as *deprecated* now resulting in compiler warnings (which due to -Werror we treat as errors and thus the build fails). The *new* functions were actually introduced back in Ruby 1.9.2, so have been around for quite some time. We claim support for Ruby 2.0 onwards so this is more than fine. The new API replaces the old 'mark' and 'free' parameters with a struct that allows for more fine tuning/configuration. We never made use of either of those parameters and so the only members of this struct we *need* to set is the structure wrapper name and the dsize function pointer which is passed a pointer to the underlying wrapped structure to calculate its memory usage. While this is *not* required the documentation *recommends* setting it (though it doesn't say how it's used). Ruby pytests still pass after this change... Closes: #1525 Link: <https://bugs.ruby-lang.org/issues/19998> Link: <https://docs.ruby-lang.org/en/3.4/extension_rdoc.html#label-C+struct+to+Ruby+object> Signed-off-by: Andrew Clayton <a.clayton@nginx.com>
- Loading branch information