projects
/
spider.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fixed the isolation so it seems to work for messages and protocol
[spider.git]
/
cmd
/
kill.pl
diff --git
a/cmd/kill.pl
b/cmd/kill.pl
index 0d787dd6faed15336a3c3e923d6236449f88e0fb..d3614c3632f4dd5e4e1ca40623ba23b8db54f5dc 100644
(file)
--- a/
cmd/kill.pl
+++ b/
cmd/kill.pl
@@
-12,6
+12,16
@@
my $msgno;
my @out;
my @body;
my $ref;
my @out;
my @body;
my $ref;
+my $call = $self->call;
+my $full;
+
+if ($f[0] =~ /^f/io) {
+ return (1, $self->msg('e5')) if $self->priv < 5;
+ $full = 1;
+ shift @f;
+}
+
+# $DB::single = 1;
for $msgno (@f) {
$ref = DXMsg::get($msgno);
for $msgno (@f) {
$ref = DXMsg::get($msgno);
@@
-19,9
+29,15
@@
for $msgno (@f) {
push @out, "Msg $msgno not found";
next;
}
push @out, "Msg $msgno not found";
next;
}
- if ($ref->private && $self->priv < 9 && $ref->to ne $ref->call) {
+ if ($self->priv < 5 &&
+ (($ref->private && $ref->to ne $self->call && $ref->from ne $self->call) ||
+ ($ref->private == 0 && $ref->from ne $self->call))) {
push @out, "Msg $msgno not available";
next;
push @out, "Msg $msgno not available";
next;
+ }
+ Log('msg', "Message $ref->{msgno} from $ref->{from} to $ref->{to} deleted by $call");
+ if ($full) {
+ DXProt::broadcast_ak1a(DXProt::pc49($self->call, $ref->{subject}), $DXProt::me);
}
$ref->del_msg;
push @out, "Message $msgno deleted";
}
$ref->del_msg;
push @out, "Message $msgno deleted";