|
|
#1 |
|
Junior Member
Join Date: Jul 2007
Posts: 6
|
ATF Hang with $left/$right string functions
The $left() and $right() string functions will hang winamp for 30+ seconds if the tag is empty. They work just fine if the tag exists.
You can't even avoid the hang with $if / $if2 statement. It's simple to reproduce. I wanted %year% to show up as the last two digits (ie, 2007 = 07). Tried: $right(%year%,2) $right([%year%],2) [$right(%year%,2)] $if(%year%,$right(%year%,2),'??') $if(%year%,[$right(%year%,2)],'??') $IfStrEqual2(%year%,,'??',$right(%year%,2)) $IfStrEqual2(%year%,'','??',$right(%year%,2)) This error is in every version of winamp I've used, including 5.551. |
|
|
|
|
|
#2 |
|
Techorator
Winamp & Shoutcast Team Join Date: Jun 2000
Posts: 35,894
|
Reproduced. Thanks.
I already had %year% in my ATF string, so I replaced it with $if(%year%,[$right(%year%,2)],'??') and there's no problems with mp3's (and other formats) which have the Year field filled-in in the tags, but yup, on attempted playback, I got a considerable hang for any files without Year. Infact, it totally locked up Winamp for me on one file. |
|
|
|
|
|
#3 |
|
Junior Member
Join Date: Jul 2007
Posts: 6
|
Awesome
Glad you could reproduce it. I know it works for tagged material, and all my music is tagged - it's just that when I used to play wav files, winamp would freeze. I believe it will unfreeze after a while if you do an $if statement.
On a side note, I found a non-hanging asinine workaround for displaying %year% with 2 digits: $if(%year%,$lpad($mod(%year%,100),2,0),'??') So: 1847 / 100 = 18.47 = 47 1900 / 100 = 19 = 00 (from padding) This is sort of a double-post, but I didn't realize it was a $right/$left string function error when I originally posted in Tech Support. |
|
|
|
|
|
#4 |
|
Junior Member
Join Date: Jun 2009
Posts: 2
|
Any update on this? I have seen the same problem with 5.552.
|
|
|
|
|
|
#5 |
|
Junior Member
Join Date: Jun 2009
Posts: 2
|
Any update on this? I have seen the same problem with 5.552.
|
|
|
|
|
|
#6 |
|
Join Date: Sep 2003
Posts: 27,873
|
the fix is in place for the next 'proper' Winamp update.
-daz |
|
|
|
![]() |
|
|||||||
| Thread Tools | Search this Thread |
| Display Modes | |
|
|