diff --git a/common.h b/common.h index 65b34f6..e7e5d0b 100644 --- a/common.h +++ b/common.h @@ -555,7 +555,7 @@ void printfileerror(FILE* f, const char* name) { int e = errno; printf("Error: "); if(name) { printf("%s: ", name); } - printf("%s\n", f && feof(f) ? "Unexpected end-of-file" : strerror(e)); + printf("%s (%d)\n", f && feof(f) ? "Unexpected end-of-file" : strerror(e), e); } ////////////////////////////////////////////////////////////////////////////////