[Gambas-devel] bug in object creation, or in my pcre component?
Rob
sourceforge-raindog2 at ...19...
Fri Jan 21 19:15:06 CET 2005
Using the latest version of pcre I posted to the list, I noticed
some crashing behavior.
r = new Regexp("foo", "(foo)")
print r.submatches[1].text
...
r = new Regexp("bar", "(bar)")
print r.submatches[1].text
causes a segmentation fault in gbx2 on the last line, but this
code:
r = new Regexp("foo", "(foo)")
print r.submatches[1].text
...
r = NULL
r = new Regexp("bar", "(bar)")
print r.submatches[1].text
does not. Near as I can figure from sticking a bunch of
fprintf(stderr, ...)'s in my pcre component is that the Gambas
interpreter somehow instantiates the new component before
freeing the old one, resulting in r containing a null pointer
(on the C side), and forcing it to be done in two steps gets
around the problem.
So is there a problem in my component's cleanup code or is it an
interpreter thing?
Rob
More information about the Devel
mailing list