check fseek return value (coverity 1109837)
This commit is contained in:
parent
17b347a260
commit
3b42f73b5a
|
@ -360,7 +360,11 @@ struct container_ctx *container_create(const char *filename,
|
|||
* we don't know where it'll be yet!
|
||||
*/
|
||||
|
||||
fseek(ctx->fh, 108, SEEK_SET);
|
||||
if (fseek(ctx->fh, 108, SEEK_SET) == -1) {
|
||||
LOG(("directory offset seek failed"));
|
||||
free(ctx);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
return ctx;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue