svnno****@sourc*****
svnno****@sourc*****
2008年 3月 26日 (水) 13:24:07 JST
Revision: 552 http://svn.sourceforge.jp/cgi-bin/viewcvs.cgi?root=slashdotjp&view=rev&rev=552 Author: tach Date: 2008-03-26 13:24:07 +0900 (Wed, 26 Mar 2008) Log Message: ----------- fix userform object filter for Control code Modified Paths: -------------- slashjp/branches/2.5.0.192/Slash/Utility/Environment/Environment.pm -------------- next part -------------- Modified: slashjp/branches/2.5.0.192/Slash/Utility/Environment/Environment.pm =================================================================== --- slashjp/branches/2.5.0.192/Slash/Utility/Environment/Environment.pm 2008-03-25 11:16:51 UTC (rev 551) +++ slashjp/branches/2.5.0.192/Slash/Utility/Environment/Environment.pm 2008-03-26 04:24:07 UTC (rev 552) @@ -466,7 +466,6 @@ } else { $form = $static_form; } - map { $form->{$_} =~ s/\p{BidiControl}|\p{Unassigned}|\p{JoinControl}//g } keys(%$form); return defined $value ? $form->{$value} : $form; } @@ -1875,8 +1874,10 @@ sid => sub { $_[0] = '' unless $_[0] =~ Slash::Utility::Data::regexSid() }, flags => sub { $_[0] =~ s|[^a-z0-9_,]||g }, - query => sub { $_[0] =~ s|[\000-\040<>\177-\377]+| |g; + query => sub { $_[0] =~ s|[\000-\040<>\177\p{BidiControl}\p{Unassigned}\p{JoinControl}]+| |g; $_[0] =~ s|\s+| |g; }, + q => sub { $_[0] =~ s|[\000-\040<>\177\p{BidiControl}\p{Unassigned}\p{JoinControl}]+| |g; + $_[0] =~ s|\s+| |g; }, colorblock => sub { $_[0] =~ s|[^\w#,]+||g }, # What I actually want to do for userfield is allow it to match # [\w.]+, or pass emailValid(), or be changed to the return value @@ -1980,6 +1981,7 @@ if (exists $special{$key}) { $special{$key}->($data); } + $data =~ s/\p{BidiControl}|\p{Unassigned}|\p{JoinControl}//g; return $data; }