mirror of
https://github.com/Unidata/netcdf-c.git
synced 2025-01-30 16:10:44 +08:00
Merge pull request #2610 from WardF/pnetcdf-fd-fix.wif
Incorporate fix for errno check when fd < 0
This commit is contained in:
commit
b1fd4b840d
@ -1768,7 +1768,7 @@ posixio_open(const char *path,
|
||||
#endif
|
||||
if(fd < 0)
|
||||
{
|
||||
status = errno;
|
||||
status = errno ? errno : ENOENT;
|
||||
goto unwind_new;
|
||||
}
|
||||
*((int *)&nciop->fd) = fd; /* cast away const */
|
||||
|
Loading…
Reference in New Issue
Block a user