-
Notifications
You must be signed in to change notification settings - Fork 567
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Assertion failed: (rx->sublen >= (s - rx->subbeg) + i), function Perl_reg_numbered_buff_fetch #10488
Comments
From @moonlibsCreated by @moonlibs##### sample.pl ##### or ##### sample.pl ##### Assertion failed: (rx->sublen >= (s - rx->subbeg) + i), function Perl_reg_numbered_buff_fetch, file regcomp.c, line 5199. Repeatable under: Perl Info
|
From holger.lehmann@catworkx.deSame assertion fails when running the latest Ocsinventory Agent und On Fr. 16. Jul. 2010, 05:47:19, mons wrote:
bin:/home/mons/bin:/home/mons/flex/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/games:/usr/local/sbin:/usr/local/bin:/home/mons/bin
|
From @iabynOn Fri, Jul 16, 2010 at 05:47:19AM -0700, mons@cpan.org wrote:
I can't reproduce the issue for the first sample code, but can with the -- |
The RT System itself - Status changed from 'new' to 'open' |
From @khwilliamsonThis appears to be fixed, as it no longer happens in blead, but does for --Karl Williamson |
From @iabynOn Fri, Mar 25, 2011 at 01:45:11PM -0700, Karl Williamson via RT wrote:
Bisect shows it to be the following. Does that look plausible to you? commit 137165a Free up bit in ANYOF flags This is the foundation for fixing the regression RT #82610. My analysis The bit that is freed up is ANYOF_UTF8, which basically said there is -- |
From @khwilliamsonOn 03/26/2011 11:25 AM, Dave Mitchell wrote:
It's semi plausible. There have been a number of bugs in the optimizer |
@iabyn - Status changed from 'open' to 'resolved' |
From @iabynI'm just forwarding this message with a [perl #...] added in the subject ----- Forwarded message from Michael Schroeder <mls@suse.de> ----- Date: Thu, 28 Apr 2011 12:45:40 +0200 Hi Porters, This is about RT#76538, "Assertion failed: (rx->sublen >= (s The following little test program still crashes for me: my @x = ("AX=B","AAAAAAX="); What happens is that $1 is already set when "AAAAAAX=" is I'm not sure about the best way to fix this. A quick and dirty Inline Patch--- ./regcomp.c.orig 2011-04-27 14:19:37.000000000 +0000
+++ ./regcomp.c 2011-04-27 14:21:58.000000000 +0000
@@ -9912,8 +9912,23 @@ Perl_save_re_context(pTHX)
if (gvp) {
GV * const gv = *gvp;
- if (SvTYPE(gv) == SVt_PVGV && GvSV(gv))
- save_scalar(gv);
+ if (SvTYPE(gv) == SVt_PVGV && GvSV(gv)) {
+ /* this is a copy of save_scalar() without the GETMAGIC call, RT#76538 */
+ SV ** const sptr = &GvSVn(gv);
+ SV * osv = *sptr;
+ SV * nsv = newSV(0);
+ save_pushptrptr(SvREFCNT_inc_simple(gv), SvREFCNT_inc(osv), SAVEt_SV);
+ if (SvTYPE(osv) >= SVt_PVMG && SvMAGIC(osv) && SvTYPE(osv) != SVt_PVGV) {
+ if (SvGMAGICAL(osv)) {
+ const bool oldtainted = PL_tainted;
+ SvFLAGS(osv) |= (SvFLAGS(osv) &
+ (SVp_IOK|SVp_NOK|SVp_POK)) >> PRIVSHIFT;
+ PL_tainted = oldtainted;
+ }
+ mg_localize(osv, nsv, 1);
+ }
+ *sptr = nsv;
+ }
}
}
}
Cheers, -- ----- End forwarded message ----- -- |
@iabyn - Status changed from 'resolved' to 'open' |
From @khwilliamsonOn Tue May 17 03:38:38 2011, davem wrote:
This test program no longer panics. The reason is that \s no longer |
From @khwilliamsonLooking into this further makes me wonder if something I've done is I tried to construct a test case that would panic with current blead, Coming into a project, as I've done, and making patches without grokking The code I first read in regexec.c that loads swashes is in My best guess is that it was because of utf8_heavy.pl potentially trying (Any pattern that has the /aa modifiers will never load a swash, and |
From @greergaOn Sun, 27 Jan 2013, Karl Williamson via RT wrote:
RT #60508 and e9105d3 fixed an occurrence I can't get the example programs to fail with blead -- |
From @iabynOn Sun, Jan 27, 2013 at 10:11:20AM -0800, Karl Williamson via RT wrote:
I can't answer your direct question, but I'll just make a general Originally the regex engine stored all its internal state in global Cargo-culting what's already there will probably be buggy, but no more -- |
From @khwilliamsonOn 01/29/2013 10:14 AM, Dave Mitchell wrote:
This explains a lot. It turns out however, that the code in utf8.c that |
From @khwilliamsonOn Wed Jan 30 19:43:51 2013, public@khwilliamson.com wrote:
Now that save_re_context() is gone, can we close this ticket? |
From @jkeenanOn Wed Jul 24 18:37:48 2013, khw wrote:
With Perl 5.18.0 (Darwin/PPC), I get no failure or crash with either of Thank you very much. |
From @iabynOn Wed, Jul 24, 2013 at 06:37:49PM -0700, Karl Williamson via RT wrote:
Note that save_re_context() hasn't actually gone. All the parts of it So I'm not sure whether the bug is fully resolved yet -- |
From @khwilliamsonIt turns out that this has been fixed since 5.14. The first part of the script bisects to -- |
@khwilliamson - Status changed from 'open' to 'resolved' |
Migrated from rt.perl.org#76538 (status was 'resolved')
Searchable as RT76538$
The text was updated successfully, but these errors were encountered: