be more careful when searching for a decoder

git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6396 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
beveloper 2004-01-28 23:04:01 +00:00
parent 7f823d473b
commit 6c6da58bf4

View File

@ -103,9 +103,15 @@ AddOnManager::GetDecoderForFormat(xfer_entry_ref *_decoderRef,
|| format.type == B_MEDIA_MULTISTREAM)
&& format.Encoding() == 0)
return B_MEDIA_BAD_FORMAT;
if (format.type == B_MEDIA_NO_TYPE
|| format.type == B_MEDIA_UNKNOWN_TYPE)
return B_MEDIA_BAD_FORMAT;
BAutolock locker(fLock);
printf("AddOnManager::GetDecoderForFormat: searching decoder for encoding %ld\n", format.Encoding());
decoder_info *info;
for (fDecoderList.Rewind(); fDecoderList.GetNext(&info);) {
media_format *decoderFormat;