]> wimlib.net Git - wimlib/commitdiff
A couple cleanups from last commits
authorEric Biggers <ebiggers3@gmail.com>
Tue, 29 Apr 2014 22:04:57 +0000 (17:04 -0500)
committerEric Biggers <ebiggers3@gmail.com>
Tue, 29 Apr 2014 22:05:33 +0000 (17:05 -0500)
include/wimlib.h
include/wimlib/capture.h
src/capture_common.c
src/wildcard.c

index 6a5ba2f88509f512226cd4dc3d2d968baf0ac27b..b95fc71976e7413293409ca6d44863ee4562fb70 100644 (file)
@@ -973,7 +973,7 @@ struct wimlib_capture_source {
         * filesystem to be included in the WIM image. */
        wimlib_tchar *fs_source_path;
 
-       /** Destination path in the WIM image.  Use WIMLIB_WIM_ROOT_PATH to
+       /** Destination path in the WIM image.  Use ::WIMLIB_WIM_ROOT_PATH to
         * specify the root directory of the WIM image.  */
        wimlib_tchar *wim_target_path;
 
@@ -1828,7 +1828,7 @@ struct wimlib_add_command {
        /** Filesystem path to the file or directory tree to add.  */
        wimlib_tchar *fs_source_path;
 
-       /** Destination path in the WIM image.  Use WIMLIB_WIM_ROOT_PATH to
+       /** Destination path in the WIM image.  Use ::WIMLIB_WIM_ROOT_PATH to
         * specify the root directory of the WIM image.  */
        wimlib_tchar *wim_target_path;
 
index 8d79542f1a4073eff0f3d71ccaeb0c9615957283..d0c7a3245dc2d56cf68dd77846184dddff5c2c0c 100644 (file)
@@ -80,7 +80,7 @@ match_pattern_list(const tchar *path, size_t path_nchars,
                   const struct string_set *list);
 
 extern bool
-exclude_path(const tchar *path, size_t path_len,
+exclude_path(const tchar *path, size_t path_nchars,
             const struct capture_config *config);
 
 typedef int (*capture_tree_t)(struct wim_dentry **, const tchar *,
index 99d6af668058310869887553c8349b978dbf8564..7db7c5cfed2c616104f25c2da452f5b941f64270 100644 (file)
@@ -199,6 +199,7 @@ exclude_path(const tchar *path, size_t path_nchars,
                dummy[0] = OS_PREFERRED_PATH_SEPARATOR;
                dummy[1] = T('\0');
                path = dummy;
+               path_nchars = 1;
        }
 
        return match_pattern_list(path, path_nchars, &config->exclusion_pats) &&
index 742b564782d3219156ec5f669d2f6432d0bf1e8b..2619f47b59fe445f84d2e31012d2e6f90828464e 100644 (file)
@@ -106,16 +106,17 @@ match_wildcard(const tchar *string, const tchar *wildcard,
  *     path separators in the pattern must be @path_sep, and there cannot be
  *     consecutive path separators, and there cannot be a trailing path
  *     separator.  If there is a leading path separator, the match is attempted
- *     with the filename only; otherwise, the matchis attempted with the whole
+ *     with the filename only; otherwise, the match is attempted with the whole
  *     path.
  *
  * @path_sep
- *     Path separator character in @path and @wildcard.
+ *     Path separator character used in @path and @wildcard.
  *
  * @prefix_ok
  *     If %true, allow a prefix of @path, terminated by a path separator, to
- *     match, in addition to @path itself.  a.k.a. also return true if the
- *     wildcard actually matches one of the ancestor directories of @path.
+ *     match the pattern, in addition to @path itself.  In other words, return
+ *     %true if the pattern actually matches one of the ancestor directories of
+ *     @path.
  *
  * Returns %true if there was a match; %false if there was not.
  */