Tadashi Okoshi
slash****@users*****
2005年 10月 27日 (木) 19:26:37 JST
Index: affelio/lib/Affelio.pm
diff -u affelio/lib/Affelio.pm:1.22 affelio/lib/Affelio.pm:1.23
--- affelio/lib/Affelio.pm:1.22 Tue Oct 25 03:41:21 2005
+++ affelio/lib/Affelio.pm Thu Oct 27 19:26:37 2005
@@ -14,7 +14,7 @@
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
-# $Id: Affelio.pm,v 1.22 2005/10/24 18:41:21 slash5234 Exp $
+# $Id: Affelio.pm,v 1.23 2005/10/27 10:26:37 slash5234 Exp $
package Affelio;
{
@@ -36,6 +36,7 @@
use Affelio::misc::Debug;
use Affelio::misc::L10N;
use Affelio::misc::WebInput;
+ use Affelio::misc::Util;
use Affelio::exception::TaintedInputException;
use Affelio::exception::DBException;
use Affelio::exception::SystemException;
@@ -521,22 +522,13 @@
$self->{cmd__sendmail} = $Config->{command}->{sendmail};
#Determine userdata/..../ directory
- my $dir;
- eval{
- opendir(DIR, "$self->{top_dir}/userdata");
- while (defined($dir = readdir(DIR))) {
- if(($dir ne '.') && ($dir ne '..')
- && ($dir ne 'default') && ($dir ne 'CVS')
- && ($dir ne 'index.html')){
- $self->{site__user_dir} =
- $wi->PTN_dirname("$self->{top_dir}/userdata/$dir");
- }
- }
+ try{
+ $self->{site__user_dir} =
+ get_userdir("$self->{top_dir}/userdata");
+ }catch Error with{
+ my $e = shift;
+ throw ($e);
};
- if($@){
- throw Affelio::exception::SystemException("cannot open userdata directory.");
- }
- closedir(DIR);
#Load username and password
my $Config2 = Config::Tiny->new();
Index: affelio/lib/AffelioApp.pm
diff -u affelio/lib/AffelioApp.pm:1.12 affelio/lib/AffelioApp.pm:1.13
--- affelio/lib/AffelioApp.pm:1.12 Mon Oct 24 17:52:49 2005
+++ affelio/lib/AffelioApp.pm Thu Oct 27 19:26:37 2005
@@ -14,7 +14,7 @@
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
-# $Id: AffelioApp.pm,v 1.12 2005/10/24 08:52:49 slash5234 Exp $
+# $Id: AffelioApp.pm,v 1.13 2005/10/27 10:26:37 slash5234 Exp $
package AffelioApp;
{
@@ -184,7 +184,6 @@
return($self->{userdata_dbh});
}
-
######################################################################
#check_access
######################################################################