From: Daniel Carl <danielcarl@gmx.de>
Date: Wed, 10 Dec 2014 21:55:51 +0000 (+0100)
Subject: Use G_OPTION_ARG_FILENAME for -c option.
X-Git-Url: https://git.owens.tech/assets/dummy.html/assets/dummy.html/git?a=commitdiff_plain;h=4075f65cafa2e6cb588a571bcd36f6ba55529b52;p=vimb.git

Use G_OPTION_ARG_FILENAME for -c option.

To use G_OPTION_ARG_FILENAME instead of G_OPTION_ARG_STRING is important
according to the glib documentation.
---

diff --git a/src/main.c b/src/main.c
index 6595e72..54b9ef6 100644
--- a/src/main.c
+++ b/src/main.c
@@ -1571,7 +1571,7 @@ int main(int argc, char *argv[])
 
     static GOptionEntry opts[] = {
         {"cmd", 'C', 0, G_OPTION_ARG_CALLBACK, autocmdOptionArgFunc, "Ex command run before first page is loaded", NULL},
-        {"config", 'c', 0, G_OPTION_ARG_STRING, &vb.config.file, "Custom configuration file", NULL},
+        {"config", 'c', 0, G_OPTION_ARG_FILENAME, &vb.config.file, "Custom configuration file", NULL},
         {"embed", 'e', 0, G_OPTION_ARG_STRING, &winid, "Reparents to window specified by xid", NULL},
         {"kiosk", 'k', 0, G_OPTION_ARG_NONE, &vb.config.kioskmode, "Run in kiosk mode", NULL},
 #ifdef FEATURE_FIFO