- add support for bridges in read/write hardware bindings
This commit is contained in:
parent
f18fa040df
commit
be45b8e021
@ -11,7 +11,7 @@ Source:%name-%version.tar
|
|||||||
Summary: alterator module for tcp/ip connections configuration
|
Summary: alterator module for tcp/ip connections configuration
|
||||||
License: GPL
|
License: GPL
|
||||||
Group: System/Configuration/Other
|
Group: System/Configuration/Other
|
||||||
Requires: alterator >= 4.7-alt3 alterator-sh-functions >= 0.6-alt5 libshell >= 0.0.1-alt4
|
Requires: alterator >= 4.7-alt3 alterator-sh-functions >= 0.6-alt5 alterator-hw-functions libshell >= 0.0.1-alt4
|
||||||
Requires: alterator-l10n >= 2.1-alt9
|
Requires: alterator-l10n >= 2.1-alt9
|
||||||
Requires: alterator-net-common >= 0.7-alt1
|
Requires: alterator-net-common >= 0.7-alt1
|
||||||
Requires: alterator-net-wifi >= 0.5-alt1
|
Requires: alterator-net-wifi >= 0.5-alt1
|
||||||
|
@ -185,6 +185,7 @@ list_configuration()
|
|||||||
|
|
||||||
read_hw_binding()
|
read_hw_binding()
|
||||||
{
|
{
|
||||||
|
local name="$(real_iface "$1")";shift
|
||||||
local config=
|
local config=
|
||||||
|
|
||||||
if [ -f "$cachedir/iftab" ];then
|
if [ -f "$cachedir/iftab" ];then
|
||||||
@ -193,7 +194,7 @@ read_hw_binding()
|
|||||||
config="/etc/iftab"
|
config="/etc/iftab"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
local line="$(grep "^[[:space:]]*$1[[:space:]]" "$config")"
|
local line="$(grep "^[[:space:]]*$name[[:space:]]" "$config")"
|
||||||
|
|
||||||
if [ -z "$line" ]; then
|
if [ -z "$line" ]; then
|
||||||
echo "missing"
|
echo "missing"
|
||||||
@ -337,12 +338,12 @@ write_configuration()
|
|||||||
|
|
||||||
write_hw_binding()
|
write_hw_binding()
|
||||||
{
|
{
|
||||||
local name="$1";shift
|
local name="$(real_iface "$1")";shift
|
||||||
local value="$1";shift
|
local value="$1";shift
|
||||||
local config="$cachedir/iftab"
|
local config="$cachedir/iftab"
|
||||||
|
|
||||||
local mac="$(ifread "$name"|cut -f1)"
|
local mac="$(netdev_read_mac "$name")"
|
||||||
local businfo="$(ifread "$name"|cut -f2)"
|
local businfo="$(netdev_read_businfo "$name")"
|
||||||
|
|
||||||
if [ -s "$config" ]; then
|
if [ -s "$config" ]; then
|
||||||
sed -r \
|
sed -r \
|
||||||
|
@ -31,7 +31,7 @@
|
|||||||
|
|
||||||
;;; UI
|
;;; UI
|
||||||
|
|
||||||
width 500
|
width 600
|
||||||
height 300
|
height 300
|
||||||
|
|
||||||
(gridbox
|
(gridbox
|
||||||
@ -61,8 +61,8 @@ height 300
|
|||||||
(label colspan 2)
|
(label colspan 2)
|
||||||
|
|
||||||
;;
|
;;
|
||||||
|
(spacer)
|
||||||
(hbox align "left"
|
(hbox align "left"
|
||||||
colspan 2
|
|
||||||
(button (_ "OK") name "ok")
|
(button (_ "OK") name "ok")
|
||||||
(button (_ "Cancel") name "cancel")))
|
(button (_ "Cancel") name "cancel")))
|
||||||
|
|
||||||
|
@ -61,6 +61,9 @@
|
|||||||
|
|
||||||
;;; UI
|
;;; UI
|
||||||
|
|
||||||
|
width 400
|
||||||
|
height 200
|
||||||
|
|
||||||
(edit name "prev_name" text "" visibility #f)
|
(edit name "prev_name" text "" visibility #f)
|
||||||
(gridbox
|
(gridbox
|
||||||
columns "0;100"
|
columns "0;100"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user