]> git.ipfire.org Git - thirdparty/git.git/blobdiff - config.c
Add core.quotepath configuration variable.
[thirdparty/git.git] / config.c
index 0614c2b29fa93b66065ec6bc20712d38193aec89..4de892633037620504575eaf018415e970c8efbd 100644 (file)
--- a/config.c
+++ b/config.c
@@ -271,6 +271,11 @@ int git_default_config(const char *var, const char *value)
                return 0;
        }
 
+       if (!strcmp(var, "core.quotepath")) {
+               quote_path_fully = git_config_bool(var, value);
+               return 0;
+       }
+
        if (!strcmp(var, "core.symlinks")) {
                has_symlinks = git_config_bool(var, value);
                return 0;
@@ -523,7 +528,7 @@ static int store_aux(const char* key, const char* value)
        return 0;
 }
 
-static int write_error()
+static int write_error(void)
 {
        fprintf(stderr, "Failed to write new configuration file\n");
 
@@ -621,7 +626,7 @@ static ssize_t find_beginning_of_line(const char* contents, size_t size,
        size_t equal_offset = size, bracket_offset = size;
        ssize_t offset;
 
-       for (offset = offset_-2; offset > 0 
+       for (offset = offset_-2; offset > 0
                        && contents[offset] != '\n'; offset--)
                switch (contents[offset]) {
                        case '=': equal_offset = offset; break;
@@ -989,4 +994,3 @@ int git_config_rename_section(const char *old_name, const char *new_name)
        free(config_filename);
        return ret;
 }
-