diff -ru ./boost_1_47_0/libs/filesystem/v3/src/operations.cpp ./boost_1_47_0/libs/filesystem/v3/src/operations.cpp
|
|
|
389 | 389 | |
390 | 390 | if (type == fs::directory_file) // but not a directory symlink |
391 | 391 | { |
392 | | for (fs::directory_iterator itr(p); |
| 392 | if (ec != 0) { |
| 393 | for (fs::directory_iterator itr(p, *ec); |
393 | 394 | itr != end_dir_itr; ++itr) |
394 | | { |
395 | | fs::file_type tmp_type = query_file_type(itr->path(), ec); |
396 | | if (ec != 0 && *ec) |
397 | | return count; |
398 | | count += remove_all_aux(itr->path(), tmp_type, ec); |
| 395 | { |
| 396 | if (*ec) |
| 397 | return count; |
| 398 | fs::file_type tmp_type = query_file_type(itr->path(), ec); |
| 399 | if (*ec) |
| 400 | return count; |
| 401 | count += remove_all_aux(itr->path(), tmp_type, ec); |
| 402 | } |
| 403 | } else { |
| 404 | for (fs::directory_iterator itr(p); |
| 405 | itr != end_dir_itr; ++itr) |
| 406 | { |
| 407 | fs::file_type tmp_type = query_file_type(itr->path(), ec);; |
| 408 | count += remove_all_aux(itr->path(), tmp_type, ec); |
| 409 | } |
399 | 410 | } |
400 | 411 | } |
401 | 412 | remove_file_or_directory(p, type, ec); |