mirror of
https://github.com/claunia/SabreTools.git
synced 2025-12-16 19:14:27 +00:00
[DATFromDirParallel] Actually use the flag...
This commit is contained in:
@@ -97,17 +97,17 @@ namespace SabreTools
|
||||
|
||||
// Process the files in all subfolders
|
||||
Parallel.ForEach(Directory.EnumerateFiles(_basePath, "*", SearchOption.AllDirectories),
|
||||
new ParallelOptions { MaxDegreeOfParallelism = 4 },
|
||||
new ParallelOptions { MaxDegreeOfParallelism = _maxParallelism },
|
||||
item =>
|
||||
{
|
||||
ProcessPossibleArchive(item);
|
||||
});
|
||||
|
||||
// Now find all folders that are empty, if we are supposed to
|
||||
if (_addblanks)
|
||||
if (!_datdata.Romba && _addblanks)
|
||||
{
|
||||
Parallel.ForEach(Directory.EnumerateDirectories(_basePath, "*", SearchOption.AllDirectories),
|
||||
new ParallelOptions { MaxDegreeOfParallelism = 4 },
|
||||
new ParallelOptions { MaxDegreeOfParallelism = _maxParallelism },
|
||||
dir =>
|
||||
{
|
||||
if (Directory.EnumerateFiles(dir, "*", SearchOption.TopDirectoryOnly).Count() == 0)
|
||||
@@ -247,7 +247,7 @@ namespace SabreTools
|
||||
{
|
||||
_logger.Log(Path.GetFileName(item) + " treated like an archive");
|
||||
Parallel.ForEach(Directory.EnumerateFiles(tempSubDir, "*", SearchOption.AllDirectories),
|
||||
new ParallelOptions { MaxDegreeOfParallelism = 4 },
|
||||
new ParallelOptions { MaxDegreeOfParallelism = _maxParallelism },
|
||||
entry =>
|
||||
{
|
||||
ProcessFile(entry, tempSubDir, Path.GetFileNameWithoutExtension(item), _datdata);
|
||||
|
||||
Reference in New Issue
Block a user