-
Notifications
You must be signed in to change notification settings - Fork 272
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
GeanyGenDoc crash #1362
Comments
Try running Geany under gdb and get a backtrace. |
Maybe it is #1294? |
Thanks for the quick responses, but I think it is a system configuration problem. However if I run ./src/geany from the cloned geany directory geanygendoc works correctly. I am not sure how to resolve this (although I have found a roundabout way of getting it to run). Maybe this issue should be closed, as it is probably not a geany problem. |
If you install Geany from source, we recommend you uninstall the distribution packages because it's a little too easy to run the wrong binary, or worse, have one version load bits from the other. In theory it should work, but we've seen both users getting slightly confused, and distros making things hard on us (I didn't say Ubuntu, did I? 😁). Alternatively, make sure you're running the Geany version you expect (e.g. check the version numbers), just in case.
Looking at packages.ubuntu.com it's definitely new enough, are you sure you had the libctpl-dev package installed? |
Thanks for the advice. I have cleaned the unneeded files, installed libctpl-dev, re-cloned and recompiled. However if I select a single function there is no crash, but whether or not text is generated depends on the function parameters. I now see that the problem occurs only if I select a function with an anonymous parameter e.g. The Status pane of Geany shows something similar to I could not find anything in the Geany documentation regarding anonymous or unnamed parameters. |
The type being "local" really suggests if you have a crash it ought to be the issue from the mentioned PR… I'll try and reproduce later tonight though. |
I can't seem to reproduce, but:
|
I created a file - The executable is generated from the clones of geany and geany-plugins. GeanyGenDoc is the only plugin enabled. Opening the test file in Geany and selecting either The backtrace is attached. If you do not see the same result, I will create a more realistic setup. [Changing the line to be |
Can someone who can reproduce please run Geany under gdb and get a backtrace. |
@caclark OK I can reproduce with the file containing only a single include, I'll look into it. |
Fix crash if the tag to generate documentation for is of an unknown type. Also consolidate some code around this to validate parameters just to be more defensive in case it sill actually happens. Fixes geany#1362.
Thanks. That solves the problems. |
Fix crash if the tag to generate documentation for is of an unknown type. Also consolidate some code around this to validate parameters just to be more defensive in case it sill actually happens. Fixes geany#1362.
Running the latest geany from Ubuntu 2404:
geany 2.0-1build2
geany-common 2.0-1build2
geany-plugins 2.0-4ubuntu5
Selecting a C file function name and then Tools/Documentation Generator/Document Current Symbol
results in a crash.
Running from gdb gives:
Starting program: /usr/bin/geany
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7ffff2c006c0 (LWP 242811)]
[New Thread 0x7ffff22006c0 (LWP 242812)]
[New Thread 0x7ffff18006c0 (LWP 242813)]
[New Thread 0x7ffff0e006c0 (LWP 242814)]
[New Thread 0x7fffeb8006c0 (LWP 242815)]
[New Thread 0x7fffeae006c0 (LWP 242816)]
[New Thread 0x7fffea4006c0 (LWP 242817)]
[Thread 0x7fffeae006c0 (LWP 242816) exited]
[Thread 0x7fffeb8006c0 (LWP 242815) exited]
[Detaching after fork from child process 242819]
[New Thread 0x7fffeb8006c0 (LWP 242826)]
Thread 1 "geany" received signal SIGSEGV, Segmentation fault.
Downloading source file /usr/src/glib2.0-2.80.0-6ubuntu3.1/debian/build/deb/../../../glib/ghash.c
g_str_hash (v=0x0) at ../../../glib/ghash.c:2463
warning: 2463 ../../../glib/ghash.c: No such file or directory
Does anyone have a suggestion how to narrow this down?
The text was updated successfully, but these errors were encountered: