summaryrefslogtreecommitdiff
path: root/src/bin/embryo
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2014-08-22 18:09:12 +0900
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2014-08-22 20:14:57 +0900
commit32e51899522b63f395209180cb6353890abd52bd (patch)
treefa5173e770596fc5f30a150d336dee15cc5025c8 /src/bin/embryo
parentd043c8449262ee4cc17ea23a2e69e999e5c23bc0 (diff)
embryo_cc - check fseeek return and complain
fixes CID 996788
Diffstat (limited to 'src/bin/embryo')
-rw-r--r--src/bin/embryo/embryo_cc_sc6.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/bin/embryo/embryo_cc_sc6.c b/src/bin/embryo/embryo_cc_sc6.c
index b7cda645a0..0ae8c4e52c 100644
--- a/src/bin/embryo/embryo_cc_sc6.c
+++ b/src/bin/embryo/embryo_cc_sc6.c
@@ -827,7 +827,8 @@ assemble(FILE * fout, FILE * fin)
827 align32(&func.address); 827 align32(&func.address);
828 align32(&func.nameofs); 828 align32(&func.nameofs);
829#endif 829#endif
830 fseek(fout, publics + count * sizeof(FUNCSTUB), SEEK_SET); 830 if (fseek(fout, publics + count * sizeof(FUNCSTUB), SEEK_SET) < 0)
831 fprintf(stderr, "Error seeking\n");
831 sc_writebin(fout, &func, sizeof func); 832 sc_writebin(fout, &func, sizeof func);
832 fseek(fout, nameofs, SEEK_SET); 833 fseek(fout, nameofs, SEEK_SET);
833 sc_writebin(fout, sym->name, strlen(sym->name) + 1); 834 sc_writebin(fout, sym->name, strlen(sym->name) + 1);