Skip to content
Permalink
Browse files
Explicit check for negative positions in PHYSFS_seek().
  • Loading branch information
icculus committed Jul 23, 2001
1 parent 1bed4ab commit 2ea6feeb2b5037c1446f834e44453444f695774b
Showing with 1 addition and 0 deletions.
  1. +1 −0 physfs.c
@@ -1281,6 +1281,7 @@ int PHYSFS_seek(PHYSFS_file *handle, int pos)
assert(h != NULL);
assert(h->funcs != NULL);
BAIL_IF_MACRO(h->funcs->seek == NULL, ERR_NOT_SUPPORTED, 0);
BAIL_IF_MACRO(pos < 0, ERR_INVALID_ARGUMENT, 0);
return(h->funcs->seek(h, pos));
} /* PHYSFS_seek */

0 comments on commit 2ea6fee

Please sign in to comment.