projects
/
spider.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fix allowmultiple for real user with ssid
[spider.git]
/
perl
/
DXUser.pm
diff --git
a/perl/DXUser.pm
b/perl/DXUser.pm
index ee24c5d4a3f4b0ea76c55991a71e63a107a1bb81..85a22195f9a08de314cf0389b194cb273d4db51c 100644
(file)
--- a/
perl/DXUser.pm
+++ b/
perl/DXUser.pm
@@
-474,7
+474,10
@@
sub close
my $ip = shift;
$self->{lastin} = $main::systime;
# add a record to the connect list
my $ip = shift;
$self->{lastin} = $main::systime;
# add a record to the connect list
-# $self->put();
+ my $ref = [$startt || $self->{startt}, $main::systime];
+ push @$ref, $ip if $ip;
+ push @{$self->{connlist}}, $ref;
+ shift @{$self->{connlist}} if @{$self->{connlist}} > $maxconnlist;
}
#
}
#
@@
-897,10
+900,13
@@
sub readinjson
move($nfn, $fn);
};
move($nfn, $fn);
};
- # if we don't have a users.v4 at this point, look for a backup users.v4.o
+ # if we don't have a users.v4 at this point, look for a backup users.v4.
json, users.v4.n then users.v4.
o
unless (-e $fn) {
unless (-e $fn) {
- move($ofn, $fn);
+ move($nfn, $fn) unless -e $fn; # the users.v4 isn't there (maybe convert-users-v3-to-v4.pl
+ move("$fn.json", $fn); # from a run of convert-users-v3-to-v4.pl
+ move($ofn, $fn) unless -e $fn; # desperate now...
}
}
+
if ($ifh) {
$ifh->seek(0, 0);
} else {
if ($ifh) {
$ifh->seek(0, 0);
} else {