Bug 4171 - Default2 redirect to Default.
: Default2 redirect to Default.
Status: RESOLVED FIXED
Product: Logitech Media Server
Classification: Unclassified
Component: Skins
: 6.5.0
: All Other
: P2 normal (vote)
: ---
Assigned To: Chris Owens
http://forums.slimdevices.com/showthr...
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-09-21 08:16 UTC by KDF
Modified: 2009-09-08 09:13 UTC (History)
2 users (show)

See Also:
Category: ---


Attachments
do teh redirect (781 bytes, patch)
2006-09-21 08:17 UTC, KDF
Details | Diff
redirect any unknown skin (726 bytes, patch)
2006-09-21 23:18 UTC, KDF
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description KDF 2006-09-21 08:16:25 UTC
url points to a thread that mentions having Default2 in the prefs.  We'll likely have others that upgrade from 6.3 after 6.5.1 hits. Since default2 is gone, we'll need to redirect as we do for exbrowse3 (which I'm hoping can only be temporary in that case.
Comment 1 KDF 2006-09-21 08:17:24 UTC
Created attachment 1564 [details]
do teh redirect
Comment 2 Blackketter Dean 2006-09-21 09:01:06 UTC
bug 4172 is a dup of this, but with the additional request that we also redirect bogus skin URLs to default
Comment 3 Blackketter Dean 2006-09-21 09:02:11 UTC
*** Bug 4172 has been marked as a duplicate of this bug. ***
Comment 4 KDF 2006-09-21 09:27:07 UTC
HTTP::isaSkin can return 'default' instead of undef perhaps.

Callers in HTTP.pm only, at lines 419, 433 (processHTTP), ~1875 (newSkinTemplate).  The latter of which handles skinParent (inheritance) so shouldn't be a problem.  The first two are for the skin override, so this should happily return default for any override that is not a match to an existing skin (case insensitive)


The other place where I had to block exbrowse is in _generateContentFromFile().  We could call isaSkin from here as well, converting any override/pref to default for any non-matched value.  This would remove the need for a second disabled point for ExBrowse3.
Comment 5 Blackketter Dean 2006-09-21 18:54:23 UTC
*** Bug 4177 has been marked as a duplicate of this bug. ***
Comment 6 KDF 2006-09-21 23:18:13 UTC
Created attachment 1571 [details]
redirect any unknown skin

this will redirect any badly types in skin, or unacceptable pref.  

However, this addresses the extra request only, without handling dead skins left behind.  We don't currently overwrite the HTML dir, so we'd still need the previous patch for blocking specific names that might be in the HTML dir.
Comment 7 Chris Owens 2006-09-22 16:22:35 UTC
Who would you like me to assign this bug to, Dean?
Comment 8 Blackketter Dean 2006-09-22 16:46:01 UTC
It looks like kdf's patch is sufficient.  KDF: can you commit so we can test?  

Chris: can you test the upgrades and see what installer fixes we need on windows to discard obsolete skins?
Comment 9 KDF 2006-09-22 16:52:42 UTC
I'll have both patches in trunk and branch tonight. 

the only hole left is future skins that might get removed.  
the first patch will effectively block Default2 and ExBrowse3 for 6.5.1
Comment 10 KDF 2006-09-22 17:30:08 UTC
in truk at change 9994
in 6.5.1 at change 9995.

I made a few tweaks to what was here, better comments and BUG flags.

I'm leaving this open until testing can verify the desired effect.

thanks!
Comment 11 Chris Owens 2006-09-25 09:28:22 UTC
Is it enough to install 6.3.1 and upgrade to 6.5 to look for leftover malfunctioning skins?  Or should I install 6.2.1 -> 6.3.1 -> 6.5.0?  Or more?
Comment 12 Blackketter Dean 2006-09-25 10:00:59 UTC
Subject: Re:  Default2 redirect to Default.

I think it would be good to go through a number of upgrades and see  
what kind of junk is left over.

Comment 13 Andy Grundman 2006-09-27 18:03:53 UTC
This patch breaks stream.mp3 when it tries to send silence, isaSkin causes an infinite loop because of the idleStreams in Slim::Utils::Misc::readDirectory.
Comment 14 KDF 2006-09-27 18:16:56 UTC
try just the hardcode redirect in HTTP.pm, in _generateContentFromFile:

-	# BUG 4171:  only generate from valid skins, falling back on default if invalid.
-	$skin = isaSkin($skin);
+	# Default2 is gone, so redirect to Default.
+	if ($skin =~ /^(?:ExBrowse3|Default2)$/i) {
+ 		$skin = 'Default';
+ 	}
Comment 15 Andy Grundman 2006-09-28 04:03:28 UTC
Yeah that's probably a better fix.
Comment 16 KDF 2006-09-28 19:15:29 UTC
done at change 10087 and change 10088

goiing to mark fixed, but we can reopen if there are troubles.