aboutsummaryrefslogtreecommitdiffstats
path: root/exclude.c
diff options
context:
space:
mode:
authorWayne Davison <wayned@samba.org>2008-03-16 19:48:44 -0700
committerWayne Davison <wayned@samba.org>2008-03-16 19:50:35 -0700
commitffe8feb26500358075664f3d97a170012831f030 (patch)
treeabb83a0d7e8349abae08a880482a422498abf0f9 /exclude.c
parentc9b62cf375f393de076d0fc7a3c2748d581c54a2 (diff)
downloadandroid_external_rsync-ffe8feb26500358075664f3d97a170012831f030.tar.gz
android_external_rsync-ffe8feb26500358075664f3d97a170012831f030.tar.bz2
android_external_rsync-ffe8feb26500358075664f3d97a170012831f030.zip
Added "const" to a couple more char * args.
Diffstat (limited to 'exclude.c')
-rw-r--r--exclude.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/exclude.c b/exclude.c
index 027ea7a6..bcad88e0 100644
--- a/exclude.c
+++ b/exclude.c
@@ -517,13 +517,13 @@ void change_local_filter_dir(const char *dname, int dlen, int dir_depth)
filt_array[cur_depth] = push_local_filters(dname, dlen);
}
-static int rule_matches(char *fname, struct filter_struct *ex, int name_is_dir)
+static int rule_matches(const char *fname, struct filter_struct *ex, int name_is_dir)
{
int slash_handling, str_cnt = 0, anchored_match = 0;
int ret_match = ex->match_flags & MATCHFLG_NEGATE ? 0 : 1;
char *p, *pattern = ex->pattern;
const char *strings[16]; /* more than enough */
- char *name = fname + (*fname == '/');
+ const char *name = fname + (*fname == '/');
if (!*name)
return 0;
@@ -620,7 +620,7 @@ static void report_filter_result(char const *name,
* Return -1 if file "name" is defined to be excluded by the specified
* exclude list, 1 if it is included, and 0 if it was not matched.
*/
-int check_filter(struct filter_list_struct *listp, char *name, int name_is_dir)
+int check_filter(struct filter_list_struct *listp, const char *name, int name_is_dir)
{
struct filter_struct *ent;