You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by st...@apache.org on 2001/02/21 15:49:46 UTC

cvs commit: apr/file_io/win32 dir.c

stoddard    01/02/21 06:49:46

  Modified:    file_io/win32 dir.c
  Log:
  WIN32: Kill the dir cleanup on a directory close. Clean-up the code a bit.
  
  Revision  Changes    Path
  1.54      +2 -5      apr/file_io/win32/dir.c
  
  Index: dir.c
  ===================================================================
  RCS file: /home/cvs/apr/file_io/win32/dir.c,v
  retrieving revision 1.53
  retrieving revision 1.54
  diff -u -r1.53 -r1.54
  --- dir.c	2001/02/16 04:15:39	1.53
  +++ dir.c	2001/02/21 14:49:45	1.54
  @@ -135,11 +135,8 @@
   
   APR_DECLARE(apr_status_t) apr_dir_close(apr_dir_t *dir)
   {
  -    if (dir->dirhand != INVALID_HANDLE_VALUE && !FindClose(dir->dirhand)) {
  -        return apr_get_os_error();
  -    }
  -    dir->dirhand = INVALID_HANDLE_VALUE;
  -    return APR_SUCCESS;
  +    apr_pool_cleanup_kill(dir->cntxt, dir, dir_cleanup);
  +    return dir_cleanup(dir);
   }
   
   APR_DECLARE(apr_status_t) apr_dir_read(apr_finfo_t *finfo, apr_int32_t wanted,