소스 검색

Close handle

Johan Mattsson 2 년 전
부모
커밋
b065238fe1
1개의 변경된 파일6개의 추가작업 그리고 5개의 파일을 삭제
  1. 6 5
      engine/source/platformWin32/winFileio.cc

+ 6 - 5
engine/source/platformWin32/winFileio.cc

@@ -981,7 +981,8 @@ bool Platform::hasSubDirectory(const char *pPath)
             continue;
 
          Platform::clearExcludedDirectories();
-
+         FindClose(handle);
+         
          return true;
       }      
    }
@@ -1003,10 +1004,10 @@ static bool recurseDumpDirectories(const char *basePath, const char *subPath, Ve
    // Compose our search string - Format : ([path]/[subpath]/*)
    //-----------------------------------------------------------------------------
 
-   dsize_t trLen = basePath ? dStrlen(basePath) : 0;
-   dsize_t subtrLen = subPath ? dStrlen(subPath) : 0;
-   char trail = trLen > 0 ? basePath[trLen - 1] : '\0';
-   char subTrail = subtrLen > 0 ? subPath[subtrLen - 1] : '\0';
+   dsize_t trLen = basePath ? dStrlen(basePath) : 0;
+   dsize_t subtrLen = subPath ? dStrlen(subPath) : 0;
+   char trail = trLen > 0 ? basePath[trLen - 1] : '\0';
+   char subTrail = subtrLen > 0 ? subPath[subtrLen - 1] : '\0';
    char subLead = subtrLen > 0 ? subPath[0] : '\0';
 
    if (trail == '/')