aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Holme <steve_holme@hotmail.com>2014-03-29 23:30:58 +0000
committerSteve Holme <steve_holme@hotmail.com>2014-03-30 00:12:38 +0000
commit5b773658a88c24f7f01583aca934cabd0f01a6f0 (patch)
treeadbbc03bed3c706f5aa4546c3c380d189846b3b0
parentf559611aa14067a0fb9c6b10032bdd644437b134 (diff)
ftpserver.pl: Reworked some variable names to be more meaningful
-rwxr-xr-xtests/ftpserver.pl30
1 files changed, 15 insertions, 15 deletions
diff --git a/tests/ftpserver.pl b/tests/ftpserver.pl
index 7ebea7c0b..8d479fb34 100755
--- a/tests/ftpserver.pl
+++ b/tests/ftpserver.pl
@@ -1369,16 +1369,16 @@ sub LSUB_imap {
}
sub EXAMINE_imap {
- my ($testno) = @_;
- fix_imap_params($testno);
+ my ($mailbox) = @_;
+ fix_imap_params($mailbox);
- logmsg "EXAMINE_imap got $testno\n";
+ logmsg "EXAMINE_imap got $mailbox\n";
- if ($testno eq "") {
+ if ($mailbox eq "") {
sendcontrol "$cmdid BAD Command Argument\r\n";
}
else {
- my @data = getreplydata($testno);
+ my @data = getreplydata($mailbox);
for my $d (@data) {
sendcontrol $d;
@@ -1756,10 +1756,10 @@ sub PASS_pop3 {
}
sub RETR_pop3 {
- my ($testno) = @_;
+ my ($msgid) = @_;
my @data;
- if($testno =~ /^verifiedserver$/) {
+ if($msgid =~ /^verifiedserver$/) {
# this is the secret command that verifies that this actually is
# the curl test server
my $response = "WE ROOLZ: $$\r\n";
@@ -1773,7 +1773,7 @@ sub RETR_pop3 {
# send mail content
logmsg "retrieve a mail\n";
- @data = getreplydata($testno);
+ @data = getreplydata($msgid);
}
sendcontrol "+OK Mail transfer starts\r\n";
@@ -1812,15 +1812,15 @@ sub LIST_pop3 {
}
sub DELE_pop3 {
- my ($msg) = @_;
+ my ($msgid) = @_;
- logmsg "DELE_pop3 got $msg\n";
+ logmsg "DELE_pop3 got $msgid\n";
- if (!$msg) {
+ if (!$msgid) {
sendcontrol "-ERR Protocol error\r\n";
}
else {
- push (@deleted, $msg);
+ push (@deleted, $msgid);
sendcontrol "+OK\r\n";
}
@@ -1885,14 +1885,14 @@ sub UIDL_pop3 {
sub TOP_pop3 {
my ($args) = @_;
- my ($msg, $lines) = split(/ /, $args, 2);
+ my ($msgid, $lines) = split(/ /, $args, 2);
logmsg "TOP_pop3 got $args\n";
if (!grep /^TOP$/, @capabilities) {
sendcontrol "-ERR Unrecognized command\r\n";
}
- elsif (($msg eq "") || ($lines eq "")) {
+ elsif (($msgid eq "") || ($lines eq "")) {
sendcontrol "-ERR Protocol error\r\n";
}
else {
@@ -1903,7 +1903,7 @@ sub TOP_pop3 {
logmsg "retrieve top $lines lines of mail\n";
}
- my @data = getreplydata($msg);
+ my @data = getreplydata($msgid);
sendcontrol "+OK Mail transfer starts\r\n";