| iMatix home page | << | < | > | >> |
![]() Version 1.91 |
#include "sfldir.h" Bool close_dir ( DIRST *dir)
Close the directory stream, and free any allocated memory. You should call this function when you are done reading a directory, or you will get memory leaks. Returns TRUE if okay, FALSE if there was an error.
{ Bool rc; ASSERT (dir != NULL); #if (defined (__UNIX__) || defined (__VMS_XOPEN) || defined (__OS2__)) rc = (closedir (dir-> _dir_handle) == 0); #elif (defined (_MSC_VER) && defined (WIN32)) rc = (_findclose (dir-> _dir_handle) == 0); #elif (defined (_MSC_VER)) rc = TRUE; /* No function to close a dir */ #elif (defined (__TURBOC__)) rc = TRUE; /* No function to close a dir */ #else rc = FALSE; /* Directory access not supported */ #endif return (rc); }
| << | < | > | >> |
![]() |