Skip to content

Commit

Permalink
The WLAN SSID can now also contain a comma
Browse files Browse the repository at this point in the history
  • Loading branch information
mkreisl committed Apr 22, 2023
1 parent b338631 commit 3a52316
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ setInterfaceWlanCredentials() {

# Create buffer for holding configuration
WLANBUFFER="\n wireless-power off\n"
n=$(echo "$3" | sed 's%\\%\\\\%g' )
n=$(echo -en "$3" | sed 's%\\%\\\\%g' )
k=$(echo "$4" | sed 's%\\%\\\\%g' )
case $2 in
WEP) WLANBUFFER+=" wireless-essid $n\n nwireless-key $k" ;;
Expand Down Expand Up @@ -547,6 +547,7 @@ function scanWLANNetworksFn() {
[ "${WLAN[2]}" = "on" -a "${WLAN[1]}" = "Open" ] && WLAN[1]="WEP";
[ "${WLAN[3]}" = '' ] && WLAN[3]=0;
((X++));
WLAN[0]=$(echo ${WLAN[0]} | sed "s/,/\\\u002c/g")
WNETWORKS[$X]="${WLAN[0]},${WLAN[1]},${WLAN[2]},${WLAN[3]}";
fi
WLAN=();
Expand Down

0 comments on commit 3a52316

Please sign in to comment.