diff options
Diffstat (limited to 'Utilities/cmlibarchive/libarchive/archive_read_set_options.c')
-rw-r--r-- | Utilities/cmlibarchive/libarchive/archive_read_set_options.c | 32 |
1 files changed, 5 insertions, 27 deletions
diff --git a/Utilities/cmlibarchive/libarchive/archive_read_set_options.c b/Utilities/cmlibarchive/libarchive/archive_read_set_options.c index 2e2eea6905..2bd9b811ea 100644 --- a/Utilities/cmlibarchive/libarchive/archive_read_set_options.c +++ b/Utilities/cmlibarchive/libarchive/archive_read_set_options.c @@ -112,37 +112,15 @@ static int archive_set_filter_option(struct archive *_a, const char *m, const char *o, const char *v) { - struct archive_read *a = (struct archive_read *)_a; - struct archive_read_filter *filter; - struct archive_read_filter_bidder *bidder; - int r, rv = ARCHIVE_WARN, matched_modules = 0; - - for (filter = a->filter; filter != NULL; filter = filter->upstream) { - bidder = filter->bidder; - if (bidder == NULL) - continue; - if (bidder->options == NULL) - /* This bidder does not support option */ - continue; - if (m != NULL) { - if (strcmp(filter->name, m) != 0) - continue; - ++matched_modules; - } + (void)_a; /* UNUSED */ + (void)o; /* UNUSED */ + (void)v; /* UNUSED */ - r = bidder->options(bidder, o, v); - - if (r == ARCHIVE_FATAL) - return (ARCHIVE_FATAL); - - if (r == ARCHIVE_OK) - rv = ARCHIVE_OK; - } /* If the filter name didn't match, return a special code for * _archive_set_option[s]. */ - if (m != NULL && matched_modules == 0) + if (m != NULL) return ARCHIVE_WARN - 1; - return (rv); + return ARCHIVE_WARN; } static int |