X-Git-Url: https://wimlib.net/git/?p=wimlib;a=blobdiff_plain;f=src%2Fcapture_common.c;h=35aaee69a789724584b6d5f1cc8e55eca4e3e1bf;hp=62ab15b11eef476b6cbf31c6c776d369c61f4e1a;hb=0230cefb4cee3580a705364232feb72258994237;hpb=5aa1f3fd0bfdacf8ae14abf2f6be09f4229dc7b4 diff --git a/src/capture_common.c b/src/capture_common.c index 62ab15b1..35aaee69 100644 --- a/src/capture_common.c +++ b/src/capture_common.c @@ -72,16 +72,6 @@ do_capture_progress(struct add_image_params *params, int status, static int mangle_pat(tchar *pat, const tchar *path, unsigned long line_no) { - /* Remove quotes */ - if (pat[0] == T('"') || pat[0] == T('\'')) { - tchar quote = pat[0]; - tchar *last = pat + tstrlen(pat) - 1; - if (last > pat && *last == quote) { - tmemmove(pat, pat + 1, last - (pat + 1)); - *(last - 1) = T('\0'); - } - } - if (!is_any_path_separator(pat[0]) && pat[0] != T('\0') && pat[1] == T(':')) { @@ -127,7 +117,8 @@ do_read_capture_config_file(const tchar *config_file, tchar *buf, size_t buflen, }; ret = do_load_text_file(config_file, buf, buflen, &buf, - sections, ARRAY_LEN(sections), mangle_pat); + sections, ARRAY_LEN(sections), + LOAD_TEXT_FILE_REMOVE_QUOTES, mangle_pat); if (ret) return ret;