hi
** INFO: Geany 0.14, GTK+ 2.12.3, GLib 2.14.4
sorry cant provide gdb backtrace. but there's dbx': 1) t@1 (l@1) signal SEGV (no mapping at the fault address) in vStringNCatS at line 139 in file "vstring.c" 139 ++p; (dbx) where current thread: t@1 dbx: read of 4 bytes at address 3 failed dbx: attempt to read frame failed -- cannot get return address =>[1] vStringNCatS(string = 0x8a0c541, s = 0x11431210 "<bad address 0x11431210>", length = 0), line 139 in "vstring.c" [2] matchRegex(line = 0x8a16520, language = 0), line 443 in "lregex.c" (dbx)
2) breakpont @ vStringNCatS =>[1] vStringNCatS(string = 0x17, s = 0x8a30fa8 "/var/apache2/2.2/htdocs/adduseraction.php", length = 23U), line 132 in "vstring.c" [2] fileOpen(fileName = (nil), language = 0), line 66 in "read.c" [3] tm_source_file_parse(source_file = (nil)), line 128 in "tm_source_file.c" [4] tm_source_file_update(source_file = (nil), force = 1, recurse = 0, update_parent = 1), line 166 in "tm_source_file.c" [5] document_update_tag_list(idx = 0, update = 0), line 1959 in "document.c" [6] document_set_filetype(idx = 0, type = (nil)), line 2092 in "document.c" [7] document_open_file_full(idx = 0, filename = (nil), pos = 0, readonly = 0, ft = (nil), forced_enc = (nil)), line 1115 in "document.c" [8] document_open_file(locale_filename = 0x861ee18 "/var/apache2/2.2/htdocs/adduseraction.php", readonly = 0, ft = (nil), forced_enc = (nil)), line 688 in "document.c" [9] document_open_files(filenames = (nil), readonly = 0, ft = (nil), forced_enc = (nil)), line 1201 in "document.c" [10] on_file_open_dialog_response(dialog = 0x8889008, response = 0, user_data = (nil)), line 97 in "dialogs.c" [11] g_cclosure_marshal_VOID__INT(0x88cb768, 0x0, 0x2, 0x804729c, 0x80471fc, 0x0), at 0xd1763677 [12] g_closure_invoke(0x88cb768, 0x0, 0x2, 0x804729c, 0x80471fc), at 0xd174ef63 [13] signal_emit_unlocked_R(0x886b9c0, 0x0, 0x8889008, 0x0, 0x804729c), at 0xd1762cb6 [14] g_signal_emit_valist(0x8889008, 0x12e, 0x0, 0x8047508), at 0xd1761fc8 [15] g_signal_emit(0x8889008, 0x12e, 0x0, 0xfffffffd), at 0xd176215d [16] gtk_dialog_response(0x8889008, 0xfffffffd), at 0xd1d27f1b [17] action_widget_activated(0x88a9478, 0x8889008), at 0xd1d278ba [18] g_cclosure_marshal_VOID__VOID(0x88a81d0, 0x0, 0x1, 0x80476ac, 0x804760c, 0x0), at 0xd1763431 [19] g_closure_invoke(0x88a81d0, 0x0, 0x1, 0x80476ac, 0x804760c), at 0xd174ef63 [20] signal_emit_unlocked_R(0x823c6e8, 0x0, 0x88a9478, 0x0, 0x80476ac), at 0xd1762cb6 [21] g_signal_emit_valist(0x88a9478, 0x72, 0x0, 0x8047918), at 0xd1761fc8 [22] g_signal_emit(0x88a9478, 0x72, 0x0), at 0xd176215d [23] gtk_button_clicked(0x88a9478), at 0xd1ce4584 [24] gtk_button_finish_activate(0x88a9478, 0x1), at 0xd1ce54f3 [25] button_activate_timeout(0x88a9478), at 0xd1ce53d4 [26] gdk_threads_dispatch(0x8923b60), at 0xd1b9e7ab [27] g_timeout_dispatch(0x84ff258, 0xd1b9e768, 0x8923b60), at 0xd168a6bc [28] g_main_dispatch(0x81dd758), at 0xd1687c76 [29] g_main_context_dispatch(0x81dd758), at 0xd1688d85 [30] g_main_context_iterate(0x81dd758, 0x1, 0x1, 0x81bc0f0), at 0xd16891a2 [31] g_main_loop_run(0x86a92c8), at 0xd16897a4 [32] gtk_main(0xd1ffee28, 0x8126398, 0x81b9360, 0x22, 0x8124ee8, 0x8180b0b), at 0xd1d9a9de [33] main(argc = 1, argv = 0x8047b98), line 911 in "main.c"
On Sun, 20 Apr 2008 02:10:43 +0300, "Andras Barna" andras.barna@gmail.com wrote:
Hi,
people who didn't read the beginning of the story in IRC might be confused about this mail without any additional information ;-). So, next time please include a few introducing lines.
I'm a little confused about the backtrace as there are many NILs in the function calls which generally shouldn't be.
=>[1] vStringNCatS(string = 0x17, s = 0x8a30fa8
This is obviously the cause of the crash, as 0x17 is not a valid address for a vString object. The problem might be somewhere in lregex.c, maybe an incompatibility with the regex implementation in OpenSolaris but this is only a wild guess.
Could you try the SVN version of CTags (http://ctags.sourceforge.net), compile it and then run:
ctags /var/apache2/2.2/htdocs/adduseraction.php
to see whether it also crashes? The tagmanager code in Geany is based on CTags, I'm fearing CTags will work anyway.
Regards, Enrico
here's: bash-3.2$ ./ctags /var/apache2/2.2/htdocs/adduseraction.php bash-3.2$ cat tags !_TAG_FILE_FORMAT 2 /extended format; --format=1 will not append ;" to lines/ !_TAG_FILE_SORTED 1 /0=unsorted, 1=sorted, 2=foldcase/ !_TAG_PROGRAM_AUTHOR Darren Hiebert /dhiebert@users.sourceforge.net/ !_TAG_PROGRAM_NAME Exuberant Ctags // !_TAG_PROGRAM_URL http://ctags.sourceforge.net /official site/ !_TAG_PROGRAM_VERSION 5.6b1 // admin /var/apache2/2.2/htdocs/adduseraction.php /^$admin = $_POST['admin'];$/;" v companyid /var/apache2/2.2/htdocs/adduseraction.php /^$companyid = $_POST['companyid'];$/;" v email /var/apache2/2.2/htdocs/adduseraction.php /^$email = $_POST['email'];$/;" v name /var/apache2/2.2/htdocs/adduseraction.php /^$name = $_POST['name'];$/;" v parola /var/apache2/2.2/htdocs/adduseraction.php /^$parola = sha1($_POST['parola']);$/;" v query /var/apache2/2.2/htdocs/adduseraction.php /^$query = "INSERT INTO users(username,parola,name,email,companyid,registred,admin) VALUE('$username','$parola','$name','$email','$companyid','$registred','$admin')";$/;" v registred /var/apache2/2.2/htdocs/adduseraction.php /^$registred = date("Ymd");$/;" v results /var/apache2/2.2/htdocs/adduseraction.php /^$results = mysql_query($query);$/;" v rowcount /var/apache2/2.2/htdocs/adduseraction.php /^$rowcount = mysql_affected_rows();$/;" v username /var/apache2/2.2/htdocs/adduseraction.php /^$username = $_POST['username'];$/;" v bash-3.2$
On Tue, Apr 22, 2008 at 3:25 PM, Enrico Tröger enrico.troeger@uvena.de wrote:
On Sun, 20 Apr 2008 02:10:43 +0300, "Andras Barna" andras.barna@gmail.com wrote:
Hi,
people who didn't read the beginning of the story in IRC might be confused about this mail without any additional information ;-). So, next time please include a few introducing lines.
I'm a little confused about the backtrace as there are many NILs in the function calls which generally shouldn't be.
=>[1] vStringNCatS(string = 0x17, s = 0x8a30fa8
This is obviously the cause of the crash, as 0x17 is not a valid address for a vString object. The problem might be somewhere in lregex.c, maybe an incompatibility with the regex implementation in OpenSolaris but this is only a wild guess.
Could you try the SVN version of CTags (http://ctags.sourceforge.net), compile it and then run:
ctags /var/apache2/2.2/htdocs/adduseraction.php
to see whether it also crashes? The tagmanager code in Geany is based on CTags, I'm fearing CTags will work anyway.
Regards, Enrico
-- Get my GPG key from http://www.uvena.de/pub.asc
Geany mailing list Geany@uvena.de http://lists.uvena.de/cgi-bin/mailman/listinfo/geany
On Sun, 20 Apr 2008 02:10:43 +0300 "Andras Barna" andras.barna@gmail.com wrote:
hi
** INFO: Geany 0.14, GTK+ 2.12.3, GLib 2.14.4
sorry cant provide gdb backtrace. but there's dbx':
Thanks for the trace - but can you provide us with one of the PHP source files that causes Geany to crash - or if not a small test case that we can use to reproduce it?
I had a quick look at the trace and I guess it might be a bug in the regex engine, but not sure, the backtrace only showed 2 frames. (The regex engine we use is from CTags, so it's unlikely).
Regards, Nick
On Tue, 22 Apr 2008 15:33:01 +0100, Nick Treleaven nick.treleaven@btinternet.com wrote:
On Sun, 20 Apr 2008 02:10:43 +0300 "Andras Barna" andras.barna@gmail.com wrote:
hi
** INFO: Geany 0.14, GTK+ 2.12.3, GLib 2.14.4
sorry cant provide gdb backtrace. but there's dbx':
Thanks for the trace - but can you provide us with one of the PHP source files that causes Geany to crash - or if not a small test case that we can use to reproduce it?
I'm sorry. I should have mentioned it in my answer. Andras sent a link to the files on IRC. Here it is: http://sartek.net/~sartek/php.tar.gz
But at least on my system, the files open fine.
Regards, Enrico
On Tue, 22 Apr 2008 15:35:39 +0200 Enrico Tröger enrico.troeger@uvena.de wrote:
On Tue, 22 Apr 2008 15:33:01 +0100, Nick Treleaven nick.treleaven@btinternet.com wrote:
Thanks for the trace - but can you provide us with one of the PHP source files that causes Geany to crash - or if not a small test case that we can use to reproduce it?
I'm sorry. I should have mentioned it in my answer. Andras sent a link to the files on IRC. Here it is: http://sartek.net/~sartek/php.tar.gz
Thanks.
But at least on my system, the files open fine.
Yes, on Fedora 5 they also open fine.
CTags has no relevant updates over Geany 0.14 for lregex.c, so it's strange that CTags works.
But it might help to see more of the backtrace after the segfault, e.g. what functions called matchRegex().
Also for debugging it might be more useful to get a trace from a build with no optimization, as it seems a number of static functions called by matchRegex() have been optimized out, and this is probably where the problem is.
Regards, Nick
with -g3 and -Wdisabled-optimization
t@1 (l@1) signal SEGV (no mapping at the fault address) in vStringNCatS at line 135 in file "vstring.c" 135 while (*p != '\0' && remain > 0) (dbx) where current thread: t@1 dbx: read of 4 bytes at address 3 failed dbx: attempt to read frame failed -- cannot get return address =>[1] vStringNCatS(string = 0x8a56ab0, s = 0x114b1f80 "<bad address 0x114b1f80>", length = 0), line 135 in "vstring.c" [2] substitute(in = 0x8a58fc0 "$username = $_POST['username'];\n", out = 0x8a4b048 "\3", nmatch = 10, pmatch = 0x8046ec8), line 443 in "lregex.c" [3] matchTagPattern(line = 0x8a56a98, patbuf = 0x8a51ce8, pmatch = 0x8046ec8), line 457 in "lregex.c" [4] matchRegexPattern(line = 0x8a56a98, patbuf = 0x8a51ce8), line 497 in "lregex.c" (dbx)
t@1 (l@1) stopped in vStringNCatS at line 132 in file "vstring.c" 132 const char *p = s; (dbx) where current thread: t@1 =>[1] vStringNCatS(string = 0x8a59ba0, s = 0x87c4298 "/var/apache2/2.2/htdocs/adduseraction.php", length = 23U), line 132 in "vstring.c" [2] vStringNCopyS(string = 0x8a59ba0, s = 0x87c4298 "/var/apache2/2.2/htdocs/adduseraction.php", length = 23U), line 203 in "vstring.c" [3] setInputFileName(fileName = 0x87c4298 "/var/apache2/2.2/htdocs/adduseraction.php"), line 66 in "read.c" [4] fileOpen(fileName = 0x87c4298 "/var/apache2/2.2/htdocs/adduseraction.php", language = 6), line 264 in "read.c" [5] tm_source_file_parse(source_file = 0x8a4bc48), line 128 in "tm_source_file.c" [6] tm_source_file_update(source_file = 0x8a4bc48, force = 1, recurse = 0, update_parent = 1), line 166 in "tm_source_file.c" [7] document_update_tag_list(idx = 0, update = 1), line 1959 in "document.c" [8] document_set_filetype(idx = 0, type = 0x840ce40), line 2092 in "document.c" [9] document_open_file_full(idx = 0, filename = 0x889f3c8 "/var/apache2/2.2/htdocs/adduseraction.php", pos = 0, readonly = 0, ft = (nil), forced_enc = (nil)), line 1115 in "document.c" [10] document_open_file(locale_filename = 0x889f3c8 "/var/apache2/2.2/htdocs/adduseraction.php", readonly = 0, ft = (nil), forced_enc = (nil)), line 688 in "document.c" [11] document_open_files(filenames = 0x88f4848, readonly = 0, ft = (nil), forced_enc = (nil)), line 1201 in "document.c" [12] on_file_open_dialog_response(dialog = 0x886e028, response = -3, user_data = (nil)), line 97 in "dialogs.c" [13] g_cclosure_marshal_VOID__INT(0x88ea368, 0x0, 0x2, 0x80472bc, 0x804721c, 0x0), at 0xd17b3677 [14] g_closure_invoke(0x88ea368, 0x0, 0x2, 0x80472bc, 0x804721c), at 0xd179ef63 [15] signal_emit_unlocked_R(0x8858ad0, 0x0, 0x886e028, 0x0, 0x80472bc), at 0xd17b2cb6 [16] g_signal_emit_valist(0x886e028, 0x12e, 0x0, 0x8047528), at 0xd17b1fc8 [17] g_signal_emit(0x886e028, 0x12e, 0x0, 0xfffffffd), at 0xd17b215d [18] gtk_dialog_response(0x886e028, 0xfffffffd), at 0xd1bc7f1b [19] action_widget_activated(0x88c84b0, 0x886e028), at 0xd1bc78ba [20] g_cclosure_marshal_VOID__VOID(0x88bfbd0, 0x0, 0x1, 0x80476cc, 0x804762c, 0x0), at 0xd17b3431 [21] g_closure_invoke(0x88bfbd0, 0x0, 0x1, 0x80476cc, 0x804762c), at 0xd179ef63 [22] signal_emit_unlocked_R(0x8255410, 0x0, 0x88c84b0, 0x0, 0x80476cc), at 0xd17b2cb6 [23] g_signal_emit_valist(0x88c84b0, 0x72, 0x0, 0x8047938), at 0xd17b1fc8 [24] g_signal_emit(0x88c84b0, 0x72, 0x0), at 0xd17b215d [25] gtk_button_clicked(0x88c84b0), at 0xd1b84584 [26] gtk_button_finish_activate(0x88c84b0, 0x1), at 0xd1b854f3 [27] button_activate_timeout(0x88c84b0), at 0xd1b853d4 [28] gdk_threads_dispatch(0x89eebc0), at 0xd17fe7ab [29] g_timeout_dispatch(0x893da78, 0xd17fe768, 0x89eebc0), at 0xd1a2a6bc [30] g_main_dispatch(0x81f79b0), at 0xd1a27c76 [31] g_main_context_dispatch(0x81f79b0), at 0xd1a28d85 [32] g_main_context_iterate(0x81f79b0, 0x1, 0x1, 0x81d5bb0), at 0xd1a291a2 [33] g_main_loop_run(0x86c3190), at 0xd1a297a4 [34] gtk_main(0x0, 0x81a6a18, 0x5, 0x81bdc58, 0x8047b60, 0x8184545), at 0xd1c3a9de [35] main(argc = 1, argv = 0x8047b94), line 911 in "main.c" (dbx)
On Tue, Apr 22, 2008 at 7:32 PM, Nick Treleaven nick.treleaven@btinternet.com wrote:
On Tue, 22 Apr 2008 15:35:39 +0200
Enrico Tröger enrico.troeger@uvena.de wrote:
On Tue, 22 Apr 2008 15:33:01 +0100, Nick Treleaven nick.treleaven@btinternet.com wrote:
Thanks for the trace - but can you provide us with one of the PHP source files that causes Geany to crash - or if not a small test case that we can use to reproduce it?
I'm sorry. I should have mentioned it in my answer. Andras sent a link to the files on IRC. Here it is: http://sartek.net/~sartek/php.tar.gz
Thanks.
But at least on my system, the files open fine.
Yes, on Fedora 5 they also open fine.
CTags has no relevant updates over Geany 0.14 for lregex.c, so it's strange that CTags works.
But it might help to see more of the backtrace after the segfault, e.g. what functions called matchRegex().
Also for debugging it might be more useful to get a trace from a build with no optimization, as it seems a number of static functions called by matchRegex() have been optimized out, and this is probably where the problem is.
Regards, Nick _______________________________________________ Geany mailing list Geany@uvena.de http://lists.uvena.de/cgi-bin/mailman/listinfo/geany
On Tue, 22 Apr 2008 20:39:04 +0300 "Andras Barna" andras.barna@gmail.com wrote:
with -g3 and -Wdisabled-optimization
Thanks for the new trace.
Could you try the attached patch - I'm still not sure what the problem is, but it should fix the actual reason of the segfault, and might reveal the cause of the problem.
Maybe there is some code we should backport elsewhere in CTags, but lregex.c and php.c don't have any relevant changes, so I'm not really sure where to look.
One thing to try - can you print *line in the matchTagPattern() frame of the segfault trace?
BTW, I'm not familiar with dbx, but why does the first trace for the segfault end with the matchRegexPattern frame - is it possible to print the frames below that? Is the second trace just for a breakpoint?
Regards, Nick
yes i stopped in vStringNCatS after applying the patch: (dbx) print matchTagPattern `geany`lregex.c`matchTagPattern = &`geany`lregex.c`matchTagPattern(const vString *const line, const regexPattern *const patbuf, const regmatch_t *const pmatch) at 0x817a57e and: t@1 (l@1) signal SEGV (no mapping at the fault address) in strlen at 0xd018a940 0xd018a940: strlen+0x0030: movl (%eax),%ecx Current function is error 284 fprintf (errout, "%s: %s", getExecutableName (), (dbx) where current thread: t@1 dbx: read of 4 bytes at address 3 failed dbx: attempt to read frame failed -- cannot get return address [1] strlen(0x0), at 0xd018a940 [2] _ndoprnt(0x81a485b, 0x8046e20, 0x81d08e0, 0x0), at 0xd01cbe26 [3] _fprintf(0x81d08e0, 0x81a4859, 0x0, 0x81a484e), at 0xd01cdc9f =>[4] error(selection = 2, format = 0x81a7c70 "%s:%ld: null expansion of name pattern "%s"", ...), line 284 in "ctags.c" [5] matchTagPattern(line = 0x8a5a968, patbuf = 0x8a54d10, pmatch = 0x8046e88), line 464 in "lregex.c" [6] matchRegexPattern(line = 0x8a5a968, patbuf = 0x8a54d10), line 497 in "lregex.c" (dbx)
PS: i'm neither a dbx professional :) (i'm using it because gdb segfaults too when i try it with geany :P) , still need to read the whole stuff here http://docs.sun.com/app/docs/doc/819-5257
On Wed, Apr 23, 2008 at 3:25 PM, Nick Treleaven nick.treleaven@btinternet.com wrote:
On Tue, 22 Apr 2008 20:39:04 +0300
"Andras Barna" andras.barna@gmail.com wrote:
with -g3 and -Wdisabled-optimization
Thanks for the new trace.
Could you try the attached patch - I'm still not sure what the problem is, but it should fix the actual reason of the segfault, and might reveal the cause of the problem.
Maybe there is some code we should backport elsewhere in CTags, but lregex.c and php.c don't have any relevant changes, so I'm not really sure where to look.
One thing to try - can you print *line in the matchTagPattern() frame of the segfault trace?
BTW, I'm not familiar with dbx, but why does the first trace for the segfault end with the matchRegexPattern frame - is it possible to print the frames below that? Is the second trace just for a breakpoint?
Regards, Nick
Geany mailing list Geany@uvena.de http://lists.uvena.de/cgi-bin/mailman/listinfo/geany
On Wed, 23 Apr 2008 16:48:36 +0300, "Andras Barna" andras.barna@gmail.com wrote:
yes i stopped in vStringNCatS after applying the patch: (dbx) print matchTagPattern `geany`lregex.c`matchTagPattern = &`geany`lregex.c`matchTagPattern(const vString *const line, const regexPattern *const patbuf, const regmatch_t *const pmatch) at 0x817a57e and: t@1 (l@1) signal SEGV (no mapping at the fault address) in strlen at 0xd018a940 0xd018a940: strlen+0x0030: movl (%eax),%ecx Current function is error 284 fprintf (errout, "%s: %s", getExecutableName (), (dbx) where current thread: t@1 dbx: read of 4 bytes at address 3 failed dbx: attempt to read frame failed -- cannot get return address [1] strlen(0x0), at 0xd018a940 [2] _ndoprnt(0x81a485b, 0x8046e20, 0x81d08e0, 0x0), at 0xd01cbe26 [3] _fprintf(0x81d08e0, 0x81a4859, 0x0, 0x81a484e), at 0xd01cdc9f =>[4] error(selection = 2, format = 0x81a7c70 "%s:%ld: null expansion of name pattern "%s"", ...), line 284 in "ctags.c"
This causes generally an error message like:
(null): Warning: /tmp/test.php:24: null expansion of name pattern "\1"
The leading "(null)" is caused in Geany we don't set the applicaton name in ctags.c. It is just initialised with NULL. This is generally not a problem except for Windows where printf("%s", NULL) results in a segfault. I just changed this in SVN r2531. But this is yet another step to find the real problem your crashes.
Could you send the output of Geany when started on a console?
Regards, Enrico
bash-3.2$ geany -d ** INFO: Geany 0.14, GTK+ 2.12.3, GLib 2.14.4 ** INFO: Initializing plugin 'HTML Characters' ** INFO: Loaded: /usr/lib/geany/htmlchars.so (HTML Characters) ** INFO: Initializing plugin 'File Browser' ** INFO: Loaded: /usr/lib/geany/filebrowser.so (File Browser) ** INFO: /var/apache2/2.2/htdocs/adduseraction.php : PHP (UTF-8) Segmentation Fault (core dumped) bash-3.2$ pstack core core 'core' of 7712: geany -d d018a940 strlen (81a485b, 8046ec0, 81d08e0, 0) + 30 d01cdc9f fprintf (81d08e0, 81a4859, 0, 81a484e) + 9f 0816b511 error (2, 81a7c70, 8a666b0, 3, 89fd528, 89fd528) + 40 0817a5fe matchTagPattern (8a660f8, 8a61250, 8046f28, 2000) + 80 0817a708 matchRegexPattern (8a660f8, 8a61250, 0) + 56 ffffffff ???????? () bash-3.2$ pflags core core 'core' of 7712: geany -d data model = _ILP32 flags = MSACCT|MSFORK /1: flags = 0 sigmask = 0xffffbefc,0x0000ffff cursig = SIGSEGV
bash-3.2$
svn worth a try?
On Fri, Apr 25, 2008 at 7:26 PM, Enrico Tröger enrico.troeger@uvena.de wrote:
On Wed, 23 Apr 2008 16:48:36 +0300, "Andras Barna"
andras.barna@gmail.com wrote:
yes i stopped in vStringNCatS after applying the patch: (dbx) print matchTagPattern `geany`lregex.c`matchTagPattern = &`geany`lregex.c`matchTagPattern(const vString *const line, const regexPattern *const patbuf, const regmatch_t *const pmatch) at 0x817a57e and: t@1 (l@1) signal SEGV (no mapping at the fault address) in strlen at 0xd018a940 0xd018a940: strlen+0x0030: movl (%eax),%ecx Current function is error 284 fprintf (errout, "%s: %s", getExecutableName (), (dbx) where current thread: t@1 dbx: read of 4 bytes at address 3 failed dbx: attempt to read frame failed -- cannot get return address [1] strlen(0x0), at 0xd018a940 [2] _ndoprnt(0x81a485b, 0x8046e20, 0x81d08e0, 0x0), at 0xd01cbe26 [3] _fprintf(0x81d08e0, 0x81a4859, 0x0, 0x81a484e), at 0xd01cdc9f =>[4] error(selection = 2, format = 0x81a7c70 "%s:%ld: null expansion of name pattern "%s"", ...), line 284 in "ctags.c"
This causes generally an error message like:
(null): Warning: /tmp/test.php:24: null expansion of name pattern "\1"
The leading "(null)" is caused in Geany we don't set the applicaton name in ctags.c. It is just initialised with NULL. This is generally not a problem except for Windows where printf("%s", NULL) results in a segfault. I just changed this in SVN r2531. But this is yet another step to find the real problem your crashes.
Could you send the output of Geany when started on a console?
Regards, Enrico
-- Get my GPG key from http://www.uvena.de/pub.asc
Geany mailing list Geany@uvena.de http://lists.uvena.de/cgi-bin/mailman/listinfo/geany
On Fri, 25 Apr 2008 19:43:01 +0300, "Andras Barna" andras.barna@gmail.com wrote:
svn worth a try?
Sure! It only can get better ;-).
Regards, Enrico
svn worth a try?
Sure! It only can get better ;-).
Sorry to jump in unasked, but I had similar issues with Geany 0.13. When I opened PHP files, Geany crashed within vStringNCatS function.
I spent quite a time debugging and found that issue lies in regexps. Don't know if it will help with your OpenSolaris, but I can tell what I did to solve it in FreeBSD:
I compiled Geany with -lgnuregex and changed related .c files to include proper GNU regex header.
On Fri, 25 Apr 2008 20:00:12 +0300, Andris Raugulis ar@null.lv wrote:
svn worth a try?
Sure! It only can get better ;-).
Sorry to jump in unasked, but I had similar issues with Geany 0.13. When I opened PHP files, Geany crashed within vStringNCatS function.
I spent quite a time debugging and found that issue lies in regexps. Don't know if it will help with your OpenSolaris, but I can tell what I did to solve it in FreeBSD:
I compiled Geany with -lgnuregex and changed related .c files to include proper GNU regex header.
Could you next time report such problems to us? Thanks.
Both problems (your FreeBSD changes and the OpenSolaris crashes) should be fixed in SVN r2532.
Over the weekend I spent some time in installing OpenSolaris and after the third try it finally worked ;-). And luckily I was able to reproduce and fix the crash.
Once discovered the problem seems quiteobvious: we had a file "regex.h" in tagmanager/include/ which was intended to be included only if there is no system-wide regex.h (e.g. on Windows). This file contains the GNU regex interface. Due to missing #ifdefs this file was unintentionally included in every build. This was ok when the system-wide (usually in /usr/include) regex.h was compatible as it is on most GNU systems.
On those where it is not (like on OpenSolaris) it crashes. Since SVN r2532 regex.h is only included when no system-wide one was found and the related code can be compiled in with the configure option "--enable-gnu-regex". Then Geany has its own GNU regex implementation. But this should only be used when the system has no support for regex (not sure if this can happen on other systems than Windows, just in case).
There was an additional problem in the code in src/encodings.c which used the "buffer" element of the regex_t struct which seems to be only present in the GNU regex implementation. This has been removed and so the regex code in src/encodings.c will also work on non-GNU systems (hopefully).
Regards, Enrico
thank you
On Sun, Apr 27, 2008 at 6:17 PM, Enrico Tröger enrico.troeger@uvena.de wrote:
On Fri, 25 Apr 2008 20:00:12 +0300, Andris Raugulis ar@null.lv wrote:
svn worth a try?
Sure! It only can get better ;-).
Sorry to jump in unasked, but I had similar issues with Geany 0.13. When I opened PHP files, Geany crashed within vStringNCatS function.
I spent quite a time debugging and found that issue lies in regexps. Don't know if it will help with your OpenSolaris, but I can tell what I did to solve it in FreeBSD:
I compiled Geany with -lgnuregex and changed related .c files to include proper GNU regex header.
Could you next time report such problems to us? Thanks.
Both problems (your FreeBSD changes and the OpenSolaris crashes) should be fixed in SVN r2532.
Over the weekend I spent some time in installing OpenSolaris and after the third try it finally worked ;-). And luckily I was able to reproduce and fix the crash.
Once discovered the problem seems quiteobvious: we had a file "regex.h" in tagmanager/include/ which was intended to be included only if there is no system-wide regex.h (e.g. on Windows). This file contains the GNU regex interface. Due to missing #ifdefs this file was unintentionally included in every build. This was ok when the system-wide (usually in /usr/include) regex.h was compatible as it is on most GNU systems.
On those where it is not (like on OpenSolaris) it crashes. Since SVN r2532 regex.h is only included when no system-wide one was found and the related code can be compiled in with the configure option "--enable-gnu-regex". Then Geany has its own GNU regex implementation. But this should only be used when the system has no support for regex (not sure if this can happen on other systems than Windows, just in case).
There was an additional problem in the code in src/encodings.c which used the "buffer" element of the regex_t struct which seems to be only present in the GNU regex implementation. This has been removed and so the regex code in src/encodings.c will also work on non-GNU systems (hopefully).
Regards, Enrico
-- Get my GPG key from http://www.uvena.de/pub.asc
Geany mailing list Geany@uvena.de http://lists.uvena.de/cgi-bin/mailman/listinfo/geany