netifd: quote vendorid and hostname variables in dhcp script
authorHans Dedecker <dedeckeh@gmail.com>
Tue, 12 Jul 2016 12:23:58 +0000 (14:23 +0200)
committerJo-Philipp Wich <jo@mein.io>
Tue, 12 Jul 2016 12:33:49 +0000 (14:33 +0200)
Quote hostname and vendorid variables in dhcp script so they can
hold strings having white spaces

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
package/network/config/netifd/files/lib/netifd/proto/dhcp.sh

index 7085bd2aa61c94e4d789e57e95807ecfc220cdeb..abfdaaffdd1ceba418dc2736c4355787797af84e 100755 (executable)
@@ -56,8 +56,8 @@ proto_dhcp_setup() {
                -s /lib/netifd/dhcp.script \
                -f -t 0 -i "$iface" \
                ${ipaddr:+-r $ipaddr} \
-               ${hostname:+-H $hostname} \
-               ${vendorid:+-V $vendorid} \
+               ${hostname:+-H "$hostname"} \
+               ${vendorid:+-V "$vendorid"} \
                $clientid $broadcast $release $dhcpopts
 }