After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 676406 - segfault if --forms --add-list used without --list-values
segfault if --forms --add-list used without --list-values
Status: RESOLVED FIXED
Product: zenity
Classification: Core
Component: general
3.4.x
Other Linux
: Normal normal
: ---
Assigned To: Zenity Maintainers
Zenity Maintainers
Depends on:
Blocks:
 
 
Reported: 2012-05-20 01:04 UTC by Alexandre Rostovtsev
Modified: 2012-05-23 21:49 UTC
See Also:
GNOME target: ---
GNOME version: 3.3/3.4


Attachments
proposed patch (1.06 KB, patch)
2012-05-20 01:05 UTC, Alexandre Rostovtsev
none Details | Review

Description Alexandre Rostovtsev 2012-05-20 01:04:05 UTC
Both with zenity-3.4.0 and the latest git HEAD:

$ zenity --forms --add-list=foo --list-values="hello|world"
Segmentation fault (core dumped)

In other words, if the user forgot to specify a column name list, zenity attempts to create a zero-column list with elements, and naturally crashes.

IMHO the behavior should be less user-hostile by default; in other words, if no column names are specified, zenity could just add a default column.
Comment 1 Alexandre Rostovtsev 2012-05-20 01:05:53 UTC
Created attachment 214474 [details] [review]
proposed patch
Comment 2 Arx Cruz 2012-05-23 21:49:55 UTC
Applied on master.
Thanks for the patch!