Test "test-gtk-label" fails
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
DBus Menu |
Fix Released
|
Undecided
|
Charles Kerr |
Bug Description
test-gtk-label fails to pass.
DBus daemon: unix:abstract=
Client: Started with PID: 29701
Server: Started with PID: 29702
Xlib: extension "RANDR" missing on display ":101".
(lt-test-
** (process:29702): ERROR **: Unable to get name 'glib.label.test' on DBus
FAIL: test-gtk-label
DBus daemon: unix:abstract=
Client: Started with PID: 29765
Server: Started with PID: 29766
Xlib: extension "RANDR" missing on display ":101".
PASS: test-gtk-shortcut
DBus daemon: unix:abstract=
Client: Started with PID: 29821
Server: Started with PID: 29822
Xlib: extension "RANDR" missing on display ":101".
PASS: test-gtk-reorder
TEST: ./test-
Xlib: extension "RANDR" missing on display ":101".
/dbusmenu/
/dbusmenu/
PASS: ./test-gtk-parser
PASS: test-gtk-
=======
1 of 15 tests failed
Please report to <email address hidden>
=======
Related branches
- Mathieu Trudel-Lapierre: Approve
- PS Jenkins bot (community): Approve (continuous-integration)
-
Diff: 12 lines (+1/-1)1 file modifiedlibdbusmenu-gtk/client.c (+1/-1)
Changed in dbusmenu: | |
assignee: | nobody → Charles Kerr (charlesk) |
status: | New → In Progress |
Changed in dbusmenu: | |
status: | In Progress → Fix Committed |
Changed in libdbusmenu: | |
status: | Fix Committed → Fix Released |
Looks like the problem is coming from configuration #5 in test-gtk- label.json, specifically this entry:
> {"id": 89,
> "type": "standard",
> "icon-name": "blank-icon",
> "label": "blank"}
"blank-icon" is the magic string used by DBUSMENU_ MENUITEM_ ICON_NAME_ BLANK, which in libdbusmenu- gtk/client. c is processed by image_property_ handle( ) to give the menuitem a blank GtkImage.
In a subsequent call to image_property_ handle( ) we call gtk_image_ get_icon_ name() on the existing image iff its storage type is GTK_IMAGE_ICON_NAME or GTK_IMAGE_EMPTY. This is legal use of that gtk function, but in the case listed above, the name that's returned is NULL, so we need to test for that before using icon_name elsewhere in image_property_ handle( ).