diff options
Diffstat (limited to 'client/engine/Net.lib')
-rwxr-xr-x | client/engine/Net.lib | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/client/engine/Net.lib b/client/engine/Net.lib index f77705e8..b98fa478 100755 --- a/client/engine/Net.lib +++ b/client/engine/Net.lib @@ -46,7 +46,7 @@ function ogGetIpAddress () { local IP # Obtener direcciones IP. /* (comentario para Doxygen) -IP=$(ip -o addr show | awk '$2!~/lo/ && $3~/inet$/ {sub (/\/.*/, ""); printf ("%s ", $4)}') +IP=$(ip address show | awk '$2!~/lo/ { readline; if ($1~/inet$/) {sub (/\/.*/, ""); printf ("%s ", $2)}}') # Mostrar sólo la primera. (comentario para Doxygen) */ echo ${IP%% *} } |