Skip to content
This repository was archived by the owner on Oct 22, 2020. It is now read-only.

Commit 3befebb

Browse files
committed
Fix some Rubocop violations
1 parent cc7818d commit 3befebb

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

payloads/reverse_tcp.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -81,11 +81,11 @@ def constants
8181

8282
def obfuscated_variables
8383
super +
84-
%w(
84+
%w[
8585
ip port chunk_size write_a error_a shell pid sock
8686
errno shell pid sock errno errstr descriptor_spec
8787
process pipes read_a error_a num_changed_sockets input
88-
)
88+
]
8989
end
9090

9191
def raw
@@ -128,7 +128,7 @@ def post_exploit(mod)
128128

129129
if @session_started
130130
begin
131-
@network_thread.join if @network_thread
131+
@network_thread&.join
132132
rescue SignalException
133133
puts
134134
mod.emit_warning 'Caught kill signal', true
@@ -143,7 +143,7 @@ def post_exploit(mod)
143143

144144
def cleanup
145145
self.queued_commands = []
146-
@network_thread.exit if @network_thread
146+
@network_thread&.exit
147147
@server.close if @server && !@server.closed?
148148
end
149149
end

0 commit comments

Comments
 (0)