diff options
author | Darren Tucker <dtucker@zip.com.au> | 2011-10-01 18:46:12 +1000 |
---|---|---|
committer | Darren Tucker <dtucker@zip.com.au> | 2011-10-01 18:46:12 +1000 |
commit | 036876cd7d53236278fcfbd3a89e4ed9a4d9a214 (patch) | |
tree | b69287763de07a17a183d942890247ed630e5a67 /openbsd-compat/mktemp.c | |
parent | b54f50e5d0053e2c79fbb5032722aca541fdc6c1 (diff) |
- (dtucker) [openbsd-compat/mktemp.c] Fix compiler warning. ok djm
Diffstat (limited to 'openbsd-compat/mktemp.c')
-rw-r--r-- | openbsd-compat/mktemp.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/openbsd-compat/mktemp.c b/openbsd-compat/mktemp.c index 773e9eaa..4eb52f42 100644 --- a/openbsd-compat/mktemp.c +++ b/openbsd-compat/mktemp.c @@ -54,7 +54,7 @@ mktemp_internal(char *path, int slen, int mode) int fd; len = strlen(path); - if (len == 0 || slen >= len) { + if (len == 0 || slen < 0 || (size_t)slen >= len) { errno = EINVAL; return(-1); } |