Skip to content

Commit

Permalink
updated network.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
HariSekhon committed Nov 30, 2024
1 parent 92698bb commit 6cf3200
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion .bash.d/network.sh
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ halfopen(){

get_gw(){
local gw
gw="$(netstat -rn | awk '/^default/ {print $2;exit}')"
gw="$(netstat -rn | awk '/^default.*\./ {print $2;exit}')"
if [ -z "$gw" ]; then
echo "Could not find gateway, no default route! " >&2
return 1
Expand Down

0 comments on commit 6cf3200

Please sign in to comment.