From 70ae9392fbb489fc6281ff72d60ac406af02a9e2 Mon Sep 17 00:00:00 2001 From: Ole Tange Date: Tue, 25 Jun 2019 14:58:53 +0200 Subject: [PATCH] tracefile: two char dirs were treated wrongly. --- tracefile/tracefile | 2 +- wifi-reload/wifi-reload | 8 +++++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/tracefile/tracefile b/tracefile/tracefile index 7f981e0..293f0e0 100755 --- a/tracefile/tracefile +++ b/tracefile/tracefile @@ -279,7 +279,7 @@ while() { # Relative to $dir $file =~ s:^([^/]):$dir/$1:; $file =~ s:/./:/:g; # /./ => / - $file =~ s:/[^/]+/../:/:g; # /foo/../ => / + $file =~ s:/[^/]+/\.\./:/:g; # /foo/../ => / # Match files in $PWD or starting with ./ my $local = ($file =~ m<^(\Q$ENV{'PWD'}\E|\./)>); my $read = readfunc($function,$addinfo); diff --git a/wifi-reload/wifi-reload b/wifi-reload/wifi-reload index 86b996e..48f202d 100755 --- a/wifi-reload/wifi-reload +++ b/wifi-reload/wifi-reload @@ -79,9 +79,11 @@ startnm() { config() { IF=$1 sudo bash -c 'cat >> /etc/resolv.conf' < /etc/resolvconf/resolv.conf.d/head - #sudo iwconfig wls1 essid Turris - #sudo iwconfig wls1 essid Leif - sudo iwconfig wls1 essid SKYbroadbandCC95 + sudo iwconfig $IF essid Turris + #sudo iwconfig $IF essid olet + #sudo iwconfig $IF essid elverhoej + #sudo iwconfig $IF essid Leif + #sudo iwconfig wls1 essid SKYbroadbandCC95 sudo wpa_supplicant -c/etc/wpa_supplicant.conf -i$IF -d & sudo dhclient $IF & }