Magellan Linux

Diff of /mcore-src/trunk/mcore-tools/src/include/common.global.class.in

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2817 by niro, Wed Apr 12 13:21:50 2017 UTC revision 2818 by niro, Wed Apr 12 13:22:19 2017 UTC
# Line 256  system_chroot() Line 256  system_chroot()
256   chroot ${MROOT} ${cmd}   chroot ${MROOT} ${cmd}
257  }  }
258    
259    # gets ip for given interface
260    get_iface_ip()
261    {
262     local iface="$1" ip=""
263     ip=$(ip -o -f inet addr show $iface)
264     ip=${ip%%/*}
265     ip=${ip##* }
266     echo $ip
267    }
268    
269  # gets interface used to reach given ip  # gets interface used to reach given ip
270  iface_for_remote_addr()  iface_for_remote_addr()
271  {  {

Legend:
Removed from v.2817  
changed lines
  Added in v.2818