diff options
author | Patrick J Cherry <patrick@bytemark.co.uk> | 2011-08-08 13:06:44 +0100 |
---|---|---|
committer | Patrick J Cherry <patrick@bytemark.co.uk> | 2011-08-08 13:06:44 +0100 |
commit | 747a99fb5e4a3b829652c2c3693ac0575cd96dde (patch) | |
tree | a78acb799a6f5afe73edea06110e117f906e0d1e | |
parent | d2ca9f1f93e86bbcc389604b4f85cc0ecf2ef906 (diff) |
Fixed bug in pop3 handling.
-rw-r--r-- | lib/mauve/pop3_server.rb | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/lib/mauve/pop3_server.rb b/lib/mauve/pop3_server.rb index 25ee83c..e455591 100644 --- a/lib/mauve/pop3_server.rb +++ b/lib/mauve/pop3_server.rb @@ -113,38 +113,38 @@ module Mauve end def receive_data (data) - data.split(CRLF).each do |d| + data.split(CRLF).each do |cmd| break if error? - if d =~ Regexp.new('\A('+self.permitted_commands.join("|")+')\b') + if cmd =~ Regexp.new('\A('+self.permitted_commands.join("|")+')\b') case $1 when "QUIT" - do_process_quit data + do_process_quit cmd when "USER" - do_process_user data + do_process_user cmd when "PASS" - do_process_pass data + do_process_pass cmd when "STAT" - do_process_stat data + do_process_stat cmd when "LIST" - do_process_list data + do_process_list cmd when "RETR" - do_process_retr data + do_process_retr cmd when "DELE" - do_process_dele data + do_process_dele cmd when "NOOP" - do_process_noop data + do_process_noop cmd when "RSET" - do_process_rset data + do_process_rset cmd when "CAPA" - do_process_capa data + do_process_capa cmd when "UIDL" - do_process_uidl data + do_process_uidl cmd else - do_process_error data + do_process_error cmd end else - do_process_error data + do_process_error cmd end end end |