Fix NCclosedir in dpathmgr.c
Fix NCclosedir in dpathmgr.c

re: Issue https://github.com/Unidata/netcdf-c/issues/1999

NCclosedir code is incorrect. Fix.
Note that this issue crops up when using a non-VisualStudio windows build
such as Mingw because Mingq defines dirent.h, but Visual Studio does not.

Unidata/netcdf-c,Unidata/netcdf-c,Unidata/netcdf-c,Unidata/netcdf-c