Bug 478672
Summary: | Ruby short-named constant bug | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Cong Ma <frigoris.ma> | ||||||
Component: | ruby | Assignee: | Jeroen van Meeuwen <vanmeeuwen+fedora> | ||||||
Status: | CLOSED WONTFIX | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||||
Severity: | medium | Docs Contact: | |||||||
Priority: | low | ||||||||
Version: | 10 | CC: | jchadima, tagoh | ||||||
Target Milestone: | --- | ||||||||
Target Release: | --- | ||||||||
Hardware: | All | ||||||||
OS: | Linux | ||||||||
Whiteboard: | |||||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||||
Doc Text: | Story Points: | --- | |||||||
Clone Of: | Environment: | ||||||||
Last Closed: | 2009-12-18 07:28:10 UTC | Type: | --- | ||||||
Regression: | --- | Mount Type: | --- | ||||||
Documentation: | --- | CRM: | |||||||
Verified Versions: | Category: | --- | |||||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||
Cloudforms Team: | --- | Target Upstream Version: | |||||||
Embargoed: | |||||||||
Attachments: |
|
Description
Cong Ma
2009-01-03 09:05:01 UTC
This package has changed ownership in the Fedora Package Database. Reassigning to the new owner of this component. I plan to port metacploit to fedora a need this functionality. Do you plan to rapair it? If you feel like it, maybe you can help resolve the issue. From the header message from the metasploit can be seen that the bug is repaired in the latest snapshot, so I think it is findable in the changelog, and backport the patch is easier than making new one. ********************************************************************** *** * *** This version of the Ruby interpreter has significant problems, we * *** strongly recommend that you switch to version 1.8.6 until these * *** issues have been corrected. Alternatively, you can download, * *** build, and install the latest Ruby snapshot from: * *** - http://www.ruby-lang.org/ * *** For more information, please see the following URL: * *** - https://bugs.launchpad.net/bugs/282302 * *** * *********************************************************************** this is a debuan patch, please verify and if proper apply it +#! /bin/sh /usr/share/dpatch/dpatch-run +## 905_short_named_constants.dpatch by Jamie Strandboge <jamie> +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: Ubuntu: https://bugs.launchpad.net/ubuntu/+source/ruby1.8/+bug/282302 +## DP: Upstream: http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=18485 +## DP: Fix for shot-named constants breakage-- copy cbase in cref as well. + +@DPATCH@ +diff -urNad ruby1.8-1.8.7.72~/class.c ruby1.8-1.8.7.72/class.c +--- ruby1.8-1.8.7.72~/class.c 2008-06-28 05:23:54.000000000 -0500 ++++ ruby1.8-1.8.7.72/class.c 2008-10-27 12:18:21.000000000 -0500 +@@ -62,7 +62,10 @@ + NODE *fbody = body->nd_body; + + if (fbody && nd_type(fbody) == NODE_SCOPE) { +- fbody = rb_copy_node_scope(fbody, ruby_cref); ++ NODE *cref = (NODE*)fbody->nd_rval; ++ ++ if (cref) cref = cref->nd_next; ++ fbody = rb_copy_node_scope(fbody, NEW_CREF(data->klass, cref)); + } + st_insert(data->tbl, mid, (st_data_t)NEW_METHOD(fbody, body->nd_noex)); + return ST_CONTINUE; +diff -urNad ruby1.8-1.8.7.72~/eval.c ruby1.8-1.8.7.72/eval.c +--- ruby1.8-1.8.7.72~/eval.c 2008-08-03 22:24:26.000000000 -0500 ++++ ruby1.8-1.8.7.72/eval.c 2008-10-27 12:18:21.000000000 -0500 +@@ -1063,7 +1063,7 @@ + + NODE *ruby_cref = 0; + NODE *ruby_top_cref; +-#define PUSH_CREF(c) ruby_cref = NEW_NODE(NODE_CREF,(c),0,ruby_cref) ++#define PUSH_CREF(c) ruby_cref = NEW_CREF(c,ruby_cref) + #define POP_CREF() ruby_cref = ruby_cref->nd_next + + #define PUSH_SCOPE() do { \ +diff -urNad ruby1.8-1.8.7.72~/node.h ruby1.8-1.8.7.72/node.h +--- ruby1.8-1.8.7.72~/node.h 2008-07-07 01:17:24.000000000 -0500 ++++ ruby1.8-1.8.7.72/node.h 2008-10-27 12:18:21.000000000 -0500 +@@ -319,7 +319,7 @@ + #define NEW_MODULE(n,b) NEW_NODE(NODE_MODULE,n,NEW_SCOPE(b),0) + #define NEW_COLON2(c,i) NEW_NODE(NODE_COLON2,c,i,0) + #define NEW_COLON3(i) NEW_NODE(NODE_COLON3,0,i,0) +-#define NEW_CREF(c) (NEW_NODE(NODE_CREF,0,0,c)) ++#define NEW_CREF(c,n) NEW_NODE(NODE_CREF,c,0,n) + #define NEW_DOT2(b,e) NEW_NODE(NODE_DOT2,b,e,0) + #define NEW_DOT3(b,e) NEW_NODE(NODE_DOT3,b,e,0) + #define NEW_ATTRSET(a) NEW_NODE(NODE_ATTRSET,a,0,0) Created attachment 337229 [details]
Patch from the Ubuntu bug report - Rev 18485 from upstream
This patch applies to the current ruby SRPM and allows Metasploit to function properly.
Thanks, I'm rebuilding the package now and will submit to rawhide as soon as I can. Note that current F-13/12 ruby does not seem to have this bug. ruby-1.8.6.383-4.fc11 (which will shortly be included into -testing) does not have this issue. This message is a reminder that Fedora 10 is nearing its end of life. Approximately 30 (thirty) days from now Fedora will stop maintaining and issuing updates for Fedora 10. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as WONTFIX if it remains open with a Fedora 'version' of '10'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version prior to Fedora 10's end of life. Bug Reporter: Thank you for reporting this issue and we are sorry that we may not be able to fix it before Fedora 10 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora please change the 'version' of this bug to the applicable version. If you are unable to change the version, please add a comment here and someone will do it for you. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete. The process we are following is described here: http://fedoraproject.org/wiki/BugZappers/HouseKeeping Fedora 10 changed to end-of-life (EOL) status on 2009-12-17. Fedora 10 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora please feel free to reopen this bug against that version. Thank you for reporting this bug and we are sorry it could not be fixed. |