Skip to content
Myr

dir_context_is_allowed: return false instead of NULL

Before adoption: this commit came in with the history the project adopted, so no landing records it.

dir_context_is_allowed() returns a bool.

authored by Rahul Sandhu · committed by Daniel Eklöf · parent 12e5188 · Browse files · 1 file+1 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Trailers

  • Signed-off-by: Rahul Sandhu <nvraxn@posteo.uk>

Diff stats

1 file+1 added−1 removed

  • other:+1 added−1 removed

1 file+1 added−1 removed

modified:icon.c+1 added-1 removed
42 unmodified lines
43{44 static const char *const allowed_contexts[] = {"applications", "apps", "legacy"};4546 if (context == NULL)47 return NULL;47 return false;4849 for (size_t i = 0; i < sizeof(allowed_contexts) / sizeof(allowed_contexts[0]); i++) {50 if (strcasecmp(context, allowed_contexts[i]) == 0)51 return true;
848 unmodified lines