Skip to content

Commit

Permalink
Merge pull request #3816 from yalzhang/fix_gateway
Browse files Browse the repository at this point in the history
Fix the get_default_gateway
  • Loading branch information
dzhengfy authored Dec 21, 2023
2 parents fca87a6 + 0f391e9 commit d965af3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion virttest/utils_net.py
Original file line number Diff line number Diff line change
Expand Up @@ -3916,7 +3916,7 @@ def get_default_gateway(iface_name=False, session=None, ip_ver='ipv4',
else:
cmd = "%s | awk '/default/ { print $3 }'" % ip_cmd
try:
_, output = utils_misc.cmd_status_output(cmd, shell=True)
_, output = utils_misc.cmd_status_output(cmd, shell=True, session=session)
if session:
LOG.debug("Guest default gateway is %s", output)
else:
Expand Down

0 comments on commit d965af3

Please sign in to comment.