kconfig: make parent directories for the saved .config as needed
[carl9170fw.git] / config / confdata.c
index da208c47fcb844e3101382fdf38dcc9f773d24b8..52f9282e63df28c20db394e9cbc6a1ebcdd11deb 100644 (file)
@@ -927,6 +927,9 @@ int conf_write(const char *name)
                return -1;
        }
 
                return -1;
        }
 
+       if (make_parent_dir(name))
+               return -1;
+
        env = getenv("KCONFIG_OVERWRITECONFIG");
        if (env && *env) {
                *tmpname = 0;
        env = getenv("KCONFIG_OVERWRITECONFIG");
        if (env && *env) {
                *tmpname = 0;