Displaying 2 results from an estimated 2 matches for "global_config_filename".
2016 Jul 22
1
[PATCH] static const char *str -> static const char str
...ic const struct option long_options[] = {
{ "add", 1, 0, 'a' },
{ "backup", 1, 0, 'b' },
diff --git a/fish/config.c b/fish/config.c
index 0c3471a..8f10ad4 100644
--- a/fish/config.c
+++ b/fish/config.c
@@ -45,8 +45,8 @@
#ifdef HAVE_LIBCONFIG
#define GLOBAL_CONFIG_FILENAME "libguestfs-tools.conf"
-static const char *home_filename = /* $HOME/ */ ".libguestfs-tools.rc";
-static const char *etc_filename = "/etc/" GLOBAL_CONFIG_FILENAME;
+static const char home_filename[] = /* $HOME/ */ ".libguestfs-tools.rc";
+static const char et...
2016 Apr 04
2
[PATCH 1/2] Use 'error' function consistently throughout.
...;fclose: %s", filename);
config_lookup_bool (&conf, "read_only", &read_only);
@@ -101,10 +100,8 @@ parse_config (void)
CLEANUP_FREE char *path = NULL;
const char *dir = xdg_config_dirs[i - 1];
- if (asprintf (&path, "%s/libguestfs/" GLOBAL_CONFIG_FILENAME, dir) == -1) {
- perror ("asprintf");
- exit (EXIT_FAILURE);
- }
+ if (asprintf (&path, "%s/libguestfs/" GLOBAL_CONFIG_FILENAME, dir) == -1)
+ error (EXIT_FAILURE, errno, "asprintf");
read_config_from_file (path);
}
@@ -...