Skip to content

Commit

Permalink
i may not be able to reach validPathCount if validPathCount is large …
Browse files Browse the repository at this point in the history
…enough

Should never happen, but in case it does, i should be a size_t, not an int.
  • Loading branch information
AZero13 committed Jun 26, 2023
1 parent 461c9a3 commit 0114da3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion CoreFoundation/Base.subproj/CFFileUtilities.c
Original file line number Diff line number Diff line change
Expand Up @@ -1390,7 +1390,7 @@ CF_PRIVATE CFArrayRef _CFCreateCFArrayByTokenizingString(const char *values, cha
}
free(copyDirPath);
CFArrayRef pathArray = CFArrayCreate(kCFAllocatorSystemDefault, (const void **)pathList , validPathCount, &kCFTypeArrayCallBacks);
for(int i = 0; i < validPathCount; i ++) {
for(size_t i = 0; i < validPathCount; i ++) {
CFRelease(pathList[i]);
}
return pathArray;
Expand Down

0 comments on commit 0114da3

Please sign in to comment.