diff --git a/src/panfrost/tools/panfrostdump.c b/src/panfrost/tools/panfrostdump.c index 987663dd652..4837a9f6c39 100644 --- a/src/panfrost/tools/panfrostdump.c +++ b/src/panfrost/tools/panfrostdump.c @@ -358,7 +358,10 @@ main(int argc, char *argv[]) return EXIT_FAILURE; } - fseek(data_fp, doh.file_offset, SEEK_SET); + if (fseek(data_fp, doh.file_offset, SEEK_SET)) { + perror("fseek error"); + return EXIT_FAILURE; + } nbytes = fread(bos[j], 1, doh.file_size, data_fp); if (nbytes < doh.file_size) {