Skip to content

Commit 90999fb

Browse files
committed
feat(in_tail): add configurable permission error handling
Signed-off-by: Sandy Chen <[email protected]>
1 parent ef52e1d commit 90999fb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

plugins/in_tail/tail_scan_glob.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ static int tail_scan_path(const char *path, struct flb_tail_config *ctx)
205205

206206
/* Scan the given path with error checking enabled. */
207207
ret = do_glob(path, GLOB_TILDE | GLOB_ERR, NULL, &globbuf);
208-
if (ret == GLOB_ABORTED && ctx->skip_permission_errors) {
208+
if (ret == GLOB_ABORTED && !ctx->skip_permission_errors) {
209209
flb_plg_warn(ctx->ins, "read error, check permissions: %s", path);
210210
globfree(&globbuf);
211211
ret = do_glob(path, GLOB_TILDE, NULL, &globbuf);

0 commit comments

Comments
 (0)