projects
/
spider.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
1. tidy up AUTOLOAD
[spider.git]
/
perl
/
DXUser.pm
diff --git
a/perl/DXUser.pm
b/perl/DXUser.pm
index f31b79e6da0ee167b0bd83e9de92d73ccbad73ea..dec317a1928623ca40e004819cd473fdb53bda53 100644
(file)
--- a/
perl/DXUser.pm
+++ b/
perl/DXUser.pm
@@
-78,8
+78,8
@@
$lrusize = 2000;
wantann_talk => '0,Talklike Anns,yesno',
wantpc90 => '1,Req PC90,yesno',
wantnp => '1,Req New Protocol,yesno',
wantann_talk => '0,Talklike Anns,yesno',
wantpc90 => '1,Req PC90,yesno',
wantnp => '1,Req New Protocol,yesno',
- want
users
=> '9,Want Users from node,yesno',
- wantsend
users
=> '9,Send users to node,yesno',
+ want
pc16
=> '9,Want Users from node,yesno',
+ wantsend
pc16
=> '9,Send users to node,yesno',
lastoper => '9,Last for/oper,cldatetime',
nothere => '0,Not Here Text',
registered => '9,Registered?,yesno',
lastoper => '9,Last for/oper,cldatetime',
nothere => '0,Not Here Text',
registered => '9,Registered?,yesno',
@@
-91,7
+91,6
@@
$lrusize = 2000;
#no strict;
sub AUTOLOAD
{
#no strict;
sub AUTOLOAD
{
- my $self = shift;
no strict;
my $name = $AUTOLOAD;
no strict;
my $name = $AUTOLOAD;
@@
-102,12
+101,7
@@
sub AUTOLOAD
# this clever line of code creates a subroutine which takes over from autoload
# from OO Perl - Conway
*$AUTOLOAD = sub {@_ > 1 ? $_[0]->{$name} = $_[1] : $_[0]->{$name}};
# this clever line of code creates a subroutine which takes over from autoload
# from OO Perl - Conway
*$AUTOLOAD = sub {@_ > 1 ? $_[0]->{$name} = $_[1] : $_[0]->{$name}};
- &$AUTOLOAD($self, @_);
-# *{$AUTOLOAD} = sub {@_ > 1 ? $_[0]->{$name} = $_[1] : $_[0]->{$name}} ;
-# if (@_) {
-# $self->{$name} = shift;
-# }
-# return $self->{$name};
+ goto &$AUTOLOAD;
}
#use strict;
}
#use strict;
@@
-122,9
+116,9
@@
sub init
confess "need a filename in User" if !$fn;
$fn .= ".v2";
if ($mode) {
confess "need a filename in User" if !$fn;
$fn .= ".v2";
if ($mode) {
- $dbm = tie (%u, 'DB_File', $fn, O_CREAT|O_RDWR, 0666, $DB_BTREE) or confess "can't open user file: $fn ($!)";
+ $dbm = tie (%u, 'DB_File', $fn, O_CREAT|O_RDWR, 0666, $DB_BTREE) or confess "can't open user file: $fn ($!)
[rebuild it from user_asc?]
";
} else {
} else {
- $dbm = tie (%u, 'DB_File', $fn, O_RDONLY, 0666, $DB_BTREE) or confess "can't open user file: $fn ($!)";
+ $dbm = tie (%u, 'DB_File', $fn, O_RDONLY, 0666, $DB_BTREE) or confess "can't open user file: $fn ($!)
[rebuild it from user_asc?]
";
}
$filename = $fn;
}
$filename = $fn;
@@
-585,14
+579,14
@@
sub wantann_talk
return _want('ann_talk', @_);
}
return _want('ann_talk', @_);
}
-sub want
users
+sub want
pc16
{
{
- return _want('
users
', @_);
+ return _want('
pc16
', @_);
}
}
-sub wantsend
users
+sub wantsend
pc16
{
{
- return _want('
annsendusers
', @_);
+ return _want('
sendpc16
', @_);
}
sub wantlogininfo
}
sub wantlogininfo