diff options
author | ramon <ramongomez@us.es> | 2010-02-18 08:58:23 +0000 |
---|---|---|
committer | ramon <ramongomez@us.es> | 2010-02-18 08:58:23 +0000 |
commit | 59d49e836ea870732c381053c5b1f0dd8d2edf30 (patch) | |
tree | 6f761bdca9b7bb89e2c27fa0882b5a96e4013394 /client/engine/Net.lib | |
parent | 5d6bf9782fc8738e45236e9e9185fc9c3ff645fd (diff) |
Solución ticket:118, corregida función ogIpAddress.
git-svn-id: https://opengnsys.es/svn/trunk@761 a21b9725-9963-47de-94b9-378ad31fedc9
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%% *} } |