wrapper.c: add and use warn_on_fopen_errors()
[gitweb.git] / config.c
index b4a3205da32faf43db1ab990f08c0bb941af87d0..2894fbb6d0d310e6f51eaf1ba1858f2e7547f3b1 100644 (file)
--- a/config.c
+++ b/config.c
@@ -2640,6 +2640,9 @@ int git_config_rename_section_in_file(const char *config_filename,
        }
 
        if (!(config_file = fopen(config_filename, "rb"))) {
+               ret = warn_on_fopen_errors(config_filename);
+               if (ret)
+                       goto out;
                /* no config file means nothing to rename, no error */
                goto commit_and_out;
        }