bpa wrote: 
> There is a problem in LMS - it determines the types as MP3 initially and
> l;ater updates it to AAC but the cache is not updated.
> The stream plays OK if initial checking the cache for contenttype is
> commented out (code in red) - in file Slim/Schema.pm
> Proper fix would be to ensure cache is updated when content-type is
> changed but AFICT the update seems to happen in
> Slim/Schema/RemoteTrack.pm and so has a different cache.
> 
> Main root of problem is .mp3 at end means content_type is assumed to be
> "mp3" without checking or  waiting for scanning Remoteheaders of the
> http reply. Later Mime/type updates the content-type.  If the stream had
> no ".mp3" suffix - type would be "unk" until RemoteHeaders were
> received. 
> 
> > 
Code:
--------------------
  >   > 
  > sub contentType {
  >     my ($self, $urlOrObj) = @_;
  > 
  >     # Bug 15779 - if we have it in the cache then just use it
  >     # This does not even check that $urlOrObj is actually a URL
  >     # but there should be no practical chance of a key-space clash if it is 
not.
  > 
  >     if (defined $contentTypeCache{$urlOrObj}) {
  >             
  >             $log->error(" Contenttype retuning 
".$contentTypeCache{$urlOrObj} );
  >             return $contentTypeCache{$urlOrObj};
  >     }
  > 
  >     my $defaultType = 'unk';
  >     my $contentType = $defaultType;
  > 
  >     # See if we were handed a track object already, or just a plain url.
  >     my ($track, $url, $blessed) = _validTrackOrURL($urlOrObj);
  > 
  >     # We can't get a content type on a undef url
  >     if (!defined $url) {
  >             $log->error(" url undefined Contenttype retuning 
".$defaultType);
  > 
  >             return $defaultType;
  >     }
  > 
  >     # Try again for a cache hit - return immediately.
  > 
  >     if (defined $contentTypeCache{$url}) {
  >             
  >             $log->error(" Contenttype retuning ".$contentTypeCache{$url} . 
" for $url");
  >     
  >             return $contentTypeCache{$url};
  >     }
  > 
  > 
  > 
--------------------
> > 


I am a neophyte on this subject.  So basically are you saying that there
is NO way I can simply add a URL that works to my favorites?  Thank you
for your response on this.


------------------------------------------------------------------------
paul7177's Profile: http://forums.slimdevices.com/member.php?userid=69942
View this thread: http://forums.slimdevices.com/showthread.php?t=111812

_______________________________________________
Radio mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/radio

Reply via email to