diff options
author | Erik Sjölund <erik.sjolund@gmail.com> | 2023-10-02 19:36:08 +0200 |
---|---|---|
committer | Gao Xiang <hsiangkao@linux.alibaba.com> | 2023-10-08 07:42:30 +0800 |
commit | c0b5c3d2a85bc13c7b92a6de3be16c60c2308a0e (patch) | |
tree | 1c8ca79aced07f93a7bc556a8fd08fdce458433d | |
parent | 8ee07437322862dbe631f04e817d8c371fd28ec6 (diff) | |
download | erofs-utils-c0b5c3d2a85bc13c7b92a6de3be16c60c2308a0e.tar.gz |
erofs-utils: errno shouldn't set to a negative value in lib/tar.c
`errno` should be set to a non-negative value here.
Link: https://lore.kernel.org/r/CAB+1q0Q3+7s1Lt8uW6DWZ7vfjhEKhG7O7MAQhCuH-C10cr9F4g@mail.gmail.com
Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com>
-rw-r--r-- | lib/tar.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -241,7 +241,7 @@ static long long tarerofs_otoi(const char *ptr, int len) val = strtol(ptr, &endp, 8); if ((!val && endp == inp) | (*endp && *endp != ' ')) - errno = -EINVAL; + errno = EINVAL; return val; } |