summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source3/lib/sysquotas_nfs.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/source3/lib/sysquotas_nfs.c b/source3/lib/sysquotas_nfs.c
index 8272f53e3c..eff5874db6 100644
--- a/source3/lib/sysquotas_nfs.c
+++ b/source3/lib/sysquotas_nfs.c
@@ -134,6 +134,10 @@ int sys_get_nfs_quota(const char *path, const char *bdev,
memset(cutstr, '\0', len+1);
host = strncat(cutstr, mnttype, sizeof(char) * len);
testpath = strchr_m(mnttype, ':');
+ if (testpath == NULL) {
+ errno = EINVAL;
+ goto out;
+ }
testpath++;
gq_args.gqa_pathp = testpath;
gq_args.gqa_uid = id.uid;