1
mirror of https://github.com/rapid7/metasploit-payloads synced 2025-02-28 06:13:03 +01:00

Pymet fix previous transport index logic

This commit is contained in:
Spencer McIntyre 2015-07-14 14:32:57 -04:00
parent 76e649ef5e
commit 683179f4a2

View File

@ -732,7 +732,7 @@ class PythonMeterpreter(object):
if current_transport is None:
current_transport = self.transport
new_idx = self.transports.index(current_transport) - 1
if new_idx == 0:
if new_idx == -1:
new_idx = len(self.transports) - 1
return self.transports[new_idx]