Tracker: don't call debugger if a file has an invalid resource

This is a bit excessive: a file with a B_MINI_ICON resource of the wrong
size should not result in crashing Tracker, the resource should simply
be ignored.

Fixes #17668.

Change-Id: I55a210eb829e568d254d8ab569720145c0ea5a09
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5115
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
This commit is contained in:
Adrien Destugues 2022-03-20 12:06:36 +01:00 committed by Adrien Destugues
parent d5ff3cd050
commit f0a8e7e247

View File

@ -160,7 +160,6 @@ BImageResources::GetIconResource(int32 id, icon_size size,
data = LoadResource(size == B_MINI_ICON ? 'MICN' : 'ICON', id, &length);
if (data == NULL || length != (size_t)(size * size)) {
TRESPASS();
return B_ERROR;
}