diff options
author | Emmanuele Bassi <ebassi@gnome.org> | 2020-11-19 14:24:47 +0000 |
---|---|---|
committer | Emmanuele Bassi <ebassi@gnome.org> | 2020-11-19 15:20:56 +0000 |
commit | b37634dcd5c76f6a1294cd1d73bd7bd7dcb9a43b (patch) | |
tree | 675f0ab7b0d9117afd4a01aa4406877b89b63d09 | |
parent | 2d636fdda0163bedbc624712549aaa435f548e42 (diff) | |
download | gtk+-b37634dcd5c76f6a1294cd1d73bd7bd7dcb9a43b.tar.gz |
a11y: Add a fallback for the root base path
In case g_get_prgname() returns NULL, which seems to be the case for the
GTK tests.
-rw-r--r-- | gtk/a11y/gtkatspiroot.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gtk/a11y/gtkatspiroot.c b/gtk/a11y/gtkatspiroot.c index ca7730a018..48c9e60676 100644 --- a/gtk/a11y/gtkatspiroot.c +++ b/gtk/a11y/gtkatspiroot.c @@ -665,8 +665,10 @@ gtk_at_spi_root_constructed (GObject *gobject) } else { + const char *program_name = g_get_prgname (); + self->base_path = g_strconcat ("/org/gtk/application/", - g_get_prgname (), + program_name != NULL ? program_name : "unknown", "/a11y", NULL); |