if (!simple_archiver_helper_string_allowed_lists(
file_info->filename,
state->parsed->flags & 0x20000 ? 1 : 0,
- state->parsed->whitelist_contains,
- state->parsed->whitelist_begins,
- state->parsed->whitelist_ends,
- state->parsed->blacklist_contains,
- state->parsed->blacklist_begins,
- state->parsed->blacklist_ends)) {
+ state->parsed)) {
return 0;
}
const uint_fast8_t lists_allowed = simple_archiver_helper_string_allowed_lists(
link_name,
state->parsed->flags & 0x20000 ? 1 : 0,
- state->parsed->whitelist_contains,
- state->parsed->whitelist_begins,
- state->parsed->whitelist_ends,
- state->parsed->blacklist_contains,
- state->parsed->blacklist_begins,
- state->parsed->blacklist_ends);
+ state->parsed);
if (lists_allowed) {
fprintf(stderr, "SYMLINK %3" PRIu32 " of %3" PRIu32 "\n", idx + 1, u32);
if (simple_archiver_helper_string_allowed_lists(
file_info->filename,
state->parsed->flags & 0x20000 ? 1 : 0,
- state->parsed->whitelist_contains,
- state->parsed->whitelist_begins,
- state->parsed->whitelist_ends,
- state->parsed->blacklist_contains,
- state->parsed->blacklist_begins,
- state->parsed->blacklist_ends)) {
+ state->parsed)) {
file_info->other_flags |= 2;
}
const uint_fast8_t lists_allowed = simple_archiver_helper_string_allowed_lists(
buf,
state->parsed->flags & 0x20000 ? 1 : 0,
- state->parsed->whitelist_contains,
- state->parsed->whitelist_begins,
- state->parsed->whitelist_ends,
- state->parsed->blacklist_contains,
- state->parsed->blacklist_begins,
- state->parsed->blacklist_ends);
+ state->parsed);
uint8_t perms_flags[4];
if (fread(perms_flags, 1, 2, in_f) != 2) {
const uint_fast8_t lists_allowed = simple_archiver_helper_string_allowed_lists(
link_name,
state->parsed->flags & 0x20000 ? 1 : 0,
- state->parsed->whitelist_contains,
- state->parsed->whitelist_begins,
- state->parsed->whitelist_ends,
- state->parsed->blacklist_contains,
- state->parsed->blacklist_begins,
- state->parsed->blacklist_ends);
+ state->parsed);
if (!do_extract && lists_allowed) {
fprintf(stderr, "SYMLINK %3" PRIu32 " of %3" PRIu32 "\n", idx + 1, count);
} else if (simple_archiver_helper_string_allowed_lists(
file_info->filename,
state->parsed->flags & 0x20000 ? 1 : 0,
- state->parsed->whitelist_contains,
- state->parsed->whitelist_begins,
- state->parsed->whitelist_ends,
- state->parsed->blacklist_contains,
- state->parsed->blacklist_begins,
- state->parsed->blacklist_ends)) {
+ state->parsed)) {
file_info->other_flags |= 2;
}
simple_archiver_helper_string_allowed_lists(
archive_dir_name,
state->parsed->flags & 0x20000 ? 1 : 0,
- state->parsed->whitelist_contains,
- state->parsed->whitelist_begins,
- state->parsed->whitelist_ends,
- state->parsed->blacklist_contains,
- state->parsed->blacklist_begins,
- state->parsed->blacklist_ends);
+ state->parsed);
uint8_t perms_flags[4];
if (fread(perms_flags, 1, 2, in_f) != 2) {
uint_fast8_t simple_archiver_helper_string_allowed_lists(
const char *cstring,
uint_fast8_t case_i,
- const SDArchiverLinkedList *w_contains,
- const SDArchiverLinkedList *w_begins,
- const SDArchiverLinkedList *w_ends,
- const SDArchiverLinkedList *b_contains,
- const SDArchiverLinkedList *b_begins,
- const SDArchiverLinkedList *b_ends) {
- if (w_contains) {
- for (const SDArchiverLLNode *node = w_contains->head->next;
- node != w_contains->tail;
+ const SDArchiverParsed *parsed) {
+ if (parsed->whitelist_contains) {
+ for (const SDArchiverLLNode *node = parsed->whitelist_contains->head->next;
+ node != parsed->whitelist_contains->tail;
node = node->next) {
if (node->data) {
if (!simple_archiver_helper_string_contains(
}
}
}
- if (w_begins) {
- for (const SDArchiverLLNode *node = w_begins->head->next;
- node != w_begins->tail;
+ if (parsed->whitelist_begins) {
+ for (const SDArchiverLLNode *node = parsed->whitelist_begins->head->next;
+ node != parsed->whitelist_begins->tail;
node = node->next) {
if (node->data) {
if (!simple_archiver_helper_string_starts(
}
}
}
- if (w_ends) {
- for (const SDArchiverLLNode *node = w_ends->head->next;
- node != w_ends->tail;
+ if (parsed->whitelist_ends) {
+ for (const SDArchiverLLNode *node = parsed->whitelist_ends->head->next;
+ node != parsed->whitelist_ends->tail;
node = node->next) {
if (node->data) {
if (!simple_archiver_helper_string_ends(cstring, node->data, case_i)) {
}
}
- if (b_contains) {
+ if (parsed->blacklist_contains) {
uint_fast8_t contains_all = 1;
- for (const SDArchiverLLNode *node = b_contains->head->next;
- node != b_contains->tail;
+ for (const SDArchiverLLNode *node = parsed->blacklist_contains->head->next;
+ node != parsed->blacklist_contains->tail;
node = node->next) {
if (node->data) {
if (!simple_archiver_helper_string_contains(
return 0;
}
}
- if (b_begins) {
- for (const SDArchiverLLNode *node = b_begins->head->next;
- node != b_begins->tail;
+ if (parsed->blacklist_begins) {
+ for (const SDArchiverLLNode *node = parsed->blacklist_begins->head->next;
+ node != parsed->blacklist_begins->tail;
node = node->next) {
if (node->data) {
if (simple_archiver_helper_string_starts(cstring, node->data, case_i)) {
}
}
}
- if (b_ends) {
- for (const SDArchiverLLNode *node = b_ends->head->next;
- node != b_ends->tail;
+ if (parsed->blacklist_ends) {
+ for (const SDArchiverLLNode *node = parsed->blacklist_ends->head->next;
+ node != parsed->blacklist_ends->tail;
node = node->next) {
if (node->data) {
if (simple_archiver_helper_string_ends(cstring, node->data, case_i)) {