Skip to content

Commit

Permalink
Revert rapid7#4615, do it right this time
Browse files Browse the repository at this point in the history
This reverts commit a52f491, reversing
changes made to 2f4ad97.

[See rapid7#4340]
  • Loading branch information
Tod Beardsley committed Mar 24, 2015
1 parent f5947e8 commit 2eb940c
Showing 1 changed file with 3 additions and 12 deletions.
15 changes: 3 additions & 12 deletions lib/msf/ui/console/command_dispatcher/core.rb
Original file line number Diff line number Diff line change
Expand Up @@ -101,9 +101,6 @@ class Core
# Constant for disclosure date formatting in search functions
DISCLOSURE_DATE_FORMAT = "%Y-%m-%d"

# Constant for a retry timeout on using modules before they're loaded
CMD_USE_TIMEOUT = 3

# Returns the list of commands supported by this command dispatcher
def commands
{
Expand Down Expand Up @@ -2543,15 +2540,9 @@ def cmd_use(*args)
mod_name = args[0]

begin
mod = framework.modules.create(mod_name)
unless mod
# Try one more time; see #4549
sleep CMD_USE_TIMEOUT
mod = framework.modules.create(mod_name)
unless mod
print_error("Failed to load module: #{mod_name}")
return false
end
if ((mod = framework.modules.create(mod_name)) == nil)
print_error("Failed to load module: #{mod_name}")
return false
end
rescue Rex::AmbiguousArgumentError => info
print_error(info.to_s)
Expand Down

0 comments on commit 2eb940c

Please sign in to comment.