Avoids loading addons entry which aren't files (fixes #5222).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34988 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Jérôme Duval 2010-01-10 15:06:23 +00:00
parent 15c0996174
commit 4c7d632339
1 changed files with 3 additions and 0 deletions

View File

@ -184,6 +184,9 @@ MediaAddonServer::MonitorHandler::AddOnEnabled(const add_on_entry_info* info)
entry_ref ref;
make_entry_ref(info->dir_nref.device, info->dir_nref.node,
info->name, &ref);
BEntry entry(&ref, true);
if (!entry.IsFile())
return;
BPath path(&ref);
if (path.InitCheck() == B_OK)