Apply patch by Olivier Coursiere that fixes #8075: the color index variable

wasn't constrained to the size of the color array, leading to an overflow +
crash when a large number of files were scanned. Thanks!



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43036 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Rene Gollent 2011-10-31 17:07:47 +00:00
parent 62d998858f
commit f6df6995b6
1 changed files with 1 additions and 1 deletions

View File

@ -443,7 +443,7 @@ PieView::_DrawDirectory(BRect b, FileInfo* info, float parentSpan,
}
if (info != NULL && info->color >= 0 && level == 0)
colorIdx = info->color;
colorIdx = info->color % kBasePieColorCount;
else if (info != NULL)
info->color = colorIdx;