Check if errno is set.

This commit is contained in:
2021-05-25 21:53:03 +01:00
parent 906e63469e
commit 159c53a200

View File

@@ -51,7 +51,7 @@ void Filenames(const char* path)
wRc = 0;
cRc = 0;
if(!h) { rc = errno; }
if(!h) rc = errno != 0 ? errno : -1;
else
{
ret = fprintf(h, FILENAME_FORMAT, filenames[pos]);