It's useful when using multiple usb devices that should be bound to certain usb ports. Symlinks are created by hotplug handlers. Signed-off-by: Nickolay Ledovskikh <[email protected]>
@@ -31,6 +31,8 @@ proto_3g_setup() {
json_get_var dialnumber dialnumber
[ -n "$dat_device" ] && device=$dat_device
+
+ device="$(readlink -f $device)"
[ -e "$device" ] || {
proto_set_available "$interface" 0
return 1
@@ -27,6 +27,7 @@ proto_directip_setup() {
[ -n "$ctl_device" ] && device=$ctl_device
proto_notify_error "$interface" NO_DEVICE
@@ -45,6 +45,8 @@ proto_ncm_setup() {
}
echo "Control device not valid"