Change for to while

This commit is contained in:
Alex Voinea 2019-11-27 17:31:47 +02:00
parent 11ba616d73
commit 7753750fa7
No known key found for this signature in database
GPG Key ID: F5034E7CFCF2F973

View File

@ -870,9 +870,9 @@ void CardReader::presort() {
getfilename_simple(positions[sort_order[j - gap]]); getfilename_simple(positions[sort_order[j - gap]]);
char *name2 = LONGEST_FILENAME; // use the string in-place char *name2 = LONGEST_FILENAME; // use the string in-place
#if HAS_FOLDER_SORTING #if HAS_FOLDER_SORTING
for (; j >= gap && ((sdSort == SD_SORT_TIME)?(_SORT_CMP_TIME_DIR(FOLDER_SORTING)):(_SORT_CMP_DIR(FOLDER_SORTING)));) while (j >= gap && ((sdSort == SD_SORT_TIME)?_SORT_CMP_TIME_DIR(FOLDER_SORTING):_SORT_CMP_DIR(FOLDER_SORTING)))
#else #else
for (; j >= gap && ((sdSort == SD_SORT_TIME)?(_SORT_CMP_TIME_NODIR()):(_SORT_CMP_NODIR()));) while (j >= gap && ((sdSort == SD_SORT_TIME)?_SORT_CMP_TIME_NODIR():_SORT_CMP_NODIR()))
#endif #endif
{ {
sort_order[j] = sort_order[j - gap]; sort_order[j] = sort_order[j - gap];