Changeset 39099


Ignore:
Timestamp:
2013-12-16T17:28:45+01:00 (4 years ago)
Author:
jow
Message:

base-files: add network_get_protocol() to /lib/functions/network.sh

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/package/base-files/files/lib/functions/network.sh

    r39006 r39099  
    175175                done 
    176176 
    177                 # parse up state, device and physdev 
    178                 for __field in "up" "l3_device" "device"; do 
     177                # parse up state, proto, device and physdev 
     178                for __field in "up" "proto" "l3_device" "device"; do 
    179179                        if json_get_type __tmp "$__field"; then 
    180180                                __network_set_cache "${__key}_${__field}" "$__field" 
     
    382382} 
    383383 
     384# determine the protocol of the given logical interface 
     385# 1: destination variable 
     386# 2: interface 
     387network_get_protocol() { __network_device "$1" "$2" proto; } 
     388 
    384389# determine the layer 3 linux network device of the given logical interface 
    385390# 1: destination variable 
Note: See TracChangeset for help on using the changeset viewer.