From 356b5ead3b555c0331b8ec560bedb012f5a2a754 Mon Sep 17 00:00:00 2001 From: Philippe G Date: Fri, 29 Jan 2021 00:57:36 -0800 Subject: [PATCH 1/2] missing service n 302 --- Slim/Formats/RemoteStream.pm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Slim/Formats/RemoteStream.pm b/Slim/Formats/RemoteStream.pm index 8bc54c0f18b..d553c8707da 100644 --- a/Slim/Formats/RemoteStream.pm +++ b/Slim/Formats/RemoteStream.pm @@ -193,6 +193,8 @@ sub request { # socket in a CLOSE_WAIT state and leaking. $self->close(); + # some 302 services omit the protocol + $redir = ($url =~ /^(https?:)/)[0] . $redir if $redir !~ /^https?:/; main::INFOLOG && $log->info("Redirect to: $redir"); return $class->open({ From 6dd1861ee4e189fa8614b96192b91bb64b544ba7 Mon Sep 17 00:00:00 2001 From: Philippe G Date: Fri, 29 Jan 2021 19:05:06 -0800 Subject: [PATCH 2/2] don't limit to http(s) --- Slim/Formats/RemoteStream.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Slim/Formats/RemoteStream.pm b/Slim/Formats/RemoteStream.pm index d553c8707da..22a0ea16e62 100644 --- a/Slim/Formats/RemoteStream.pm +++ b/Slim/Formats/RemoteStream.pm @@ -193,8 +193,8 @@ sub request { # socket in a CLOSE_WAIT state and leaking. $self->close(); - # some 302 services omit the protocol - $redir = ($url =~ /^(https?:)/)[0] . $redir if $redir !~ /^https?:/; + # some 302 Location: omit the protocol + $redir = ($url =~ m|^(\w+://)|)[0] . $redir if $redir !~ m|^\w+://|; main::INFOLOG && $log->info("Redirect to: $redir"); return $class->open({