mirror of
https://github.com/TomHarte/CLK.git
synced 2024-12-27 16:31:31 +00:00
Eliminates repetition of the 'untypable character' test.
This commit is contained in:
parent
e3e9baeaa4
commit
ac57b37e96
@ -61,10 +61,7 @@ static void InspectCatalogue(
|
|||||||
// Remove all files with untypable characters.
|
// Remove all files with untypable characters.
|
||||||
candidate_files.erase(
|
candidate_files.erase(
|
||||||
std::remove_if(candidate_files.begin(), candidate_files.end(), [](const Storage::Disk::CPM::File &file) {
|
std::remove_if(candidate_files.begin(), candidate_files.end(), [](const Storage::Disk::CPM::File &file) {
|
||||||
for(auto c : file.name) {
|
for(auto c : file.name + file.type) {
|
||||||
if(c < 32) return true;
|
|
||||||
}
|
|
||||||
for(auto c : file.type) {
|
|
||||||
if(c < 32) return true;
|
if(c < 32) return true;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
Reference in New Issue
Block a user