projects
/
spider.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fixed some more protocol checking issues
[spider.git]
/
perl
/
DXMsg.pm
diff --git
a/perl/DXMsg.pm
b/perl/DXMsg.pm
index 11a30a4ed5458c582b3f6bb8432d03500583dc1b..5c990177330ddc26c55fd20ccd7a0fcf242e49b1 100644
(file)
--- a/
perl/DXMsg.pm
+++ b/
perl/DXMsg.pm
@@
-136,7
+136,7
@@
sub process
# this is periodic processing
if (!$self || !$line) {
# this is periodic processing
if (!$self || !$line) {
- if ($main::systime > $lastq + $queueinterval) {
+ if ($main::systime >
=
$lastq + $queueinterval) {
# wander down the work queue stopping any messages that have timed out
for (keys %busy) {
# wander down the work queue stopping any messages that have timed out
for (keys %busy) {
@@
-1235,6
+1235,9
@@
sub AUTOLOAD
$name =~ s/.*:://o;
confess "Non-existant field '$AUTOLOAD'" if !$valid{$name};
$name =~ s/.*:://o;
confess "Non-existant field '$AUTOLOAD'" if !$valid{$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}} ;
@_ ? $self->{$name} = shift : $self->{$name} ;
}
@_ ? $self->{$name} = shift : $self->{$name} ;
}