summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/shared/fstab-util.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/shared/fstab-util.c b/src/shared/fstab-util.c
index 546c81b80f..a886f6a5da 100644
--- a/src/shared/fstab-util.c
+++ b/src/shared/fstab-util.c
@@ -140,6 +140,9 @@ int fstab_find_pri(const char *options, int *ret) {
if (r < 0)
return r;
+ if ((int) pri < 0)
+ return -ERANGE;
+
*ret = (int) r;
return 1;
}