diff options
Diffstat (limited to 'src/shared/bpf-program.c')
-rw-r--r-- | src/shared/bpf-program.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/shared/bpf-program.c b/src/shared/bpf-program.c index f4bb7f390c..d924a973ec 100644 --- a/src/shared/bpf-program.c +++ b/src/shared/bpf-program.c @@ -449,11 +449,11 @@ int bpf_program_deserialize_attachment(const char *v, FDSet *fds, BPFProgram **b if (r == 0) return -EINVAL; - r = safe_atoi(sfd, &ifd); - if (r < 0) - return r; - if (ifd < 0) + ifd = parse_fd(sfd); + if (ifd == -ERANGE) return -EBADF; + if (ifd < 0) + return r; /* Extract second word: the attach type */ r = extract_first_word(&v, &sat, NULL, 0); |