equal
deleted
inserted
replaced
321 path += std::wstring(tok); |
321 path += std::wstring(tok); |
322 path += L"/"; |
322 path += L"/"; |
323 char *dirName = JavaCommonUtils::wstringToUtf8(path); |
323 char *dirName = JavaCommonUtils::wstringToUtf8(path); |
324 if (ableToOpen) |
324 if (ableToOpen) |
325 { |
325 { |
326 if (!opendir(dirName)) |
326 DIR* wDirHandle = opendir(dirName); |
|
327 if (!wDirHandle) |
327 { |
328 { |
328 ableToOpen = false; |
329 ableToOpen = false; |
329 if (mkdir(dirName,0666)<0) |
330 if (mkdir(dirName,0666)<0) |
330 { |
331 { |
331 WLOG1(EJavaFile,"FileUtilities::makeDirAll: Directory Creation Failed : %s",dirName); |
332 WLOG1(EJavaFile,"FileUtilities::makeDirAll: Directory Creation Failed : %s",dirName); |
332 delete[] dirName; |
333 delete[] dirName; |
333 delete[] stringToTokenize; |
334 delete[] stringToTokenize; |
334 return -1; |
335 return -1; |
335 } |
336 } |
336 } |
337 } |
|
338 closedir(wDirHandle); |
337 } |
339 } |
338 else |
340 else |
339 { |
341 { |
340 if (mkdir(dirName,0666)<0) |
342 if (mkdir(dirName,0666)<0) |
341 { |
343 { |