/[baselayout]/branches/baselayout-1_12/net-scripts/net/iwconfig.sh
Gentoo

Diff of /branches/baselayout-1_12/net-scripts/net/iwconfig.sh

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 2541 Revision 2542
222 key=$(iwconfig_get_wep_key) 222 key=$(iwconfig_get_wep_key)
223 223
224 iwconfig_set_mode "${iface}" "${mode}" 224 iwconfig_set_mode "${iface}" "${mode}"
225 225
226 # Now set the key 226 # Now set the key
227 if ! iwconfig "${iface}" key ${key} ; then 227 if ! eval iwconfig "${iface}" key "${key}" ; then
228 if [[ ${key} != "off" ]]; then 228 if [[ ${key} != "off" ]]; then
229 ewarn "${iface} does not support setting keys" 229 ewarn "${iface} does not support setting keys"
230 ewarn "or the parameter \"mac_key_${ESSIDVAR}\" or \"key_${ESSIDVAR}\" is incorrect" 230 ewarn "or the parameter \"mac_key_${ESSIDVAR}\" or \"key_${ESSIDVAR}\" is incorrect"
231 fi 231 fi
232 fi 232 fi
233 233
234 # Then set the ESSID 234 # Then set the ESSID
235 if ! iwconfig "${iface}" essid "${ESSID}" ; then 235 if ! eval iwconfig "${iface}" essid "${ESSID}" ; then
236 eerror "${iface} does not support setting ESSID to \"${dessid}\"" 236 eerror "${iface} does not support setting ESSID to \"${dessid}\""
237 return 1 237 return 1
238 fi 238 fi
239 239
240 channel="channel_${ifvar}" 240 channel="channel_${ifvar}"
366 if [[ ${wep_required} == "off" && ${key} != "off" ]]; then 366 if [[ ${wep_required} == "off" && ${key} != "off" ]]; then
367 key="off" 367 key="off"
368 ewarn "\"${dessid}\" is not WEP enabled - ignoring setting" 368 ewarn "\"${dessid}\" is not WEP enabled - ignoring setting"
369 fi 369 fi
370 370
371 if ! iwconfig "${iface}" key ${key} ; then 371 if ! eval iwconfig "${iface}" key "${key}" ; then
372 if [[ ${key} != "off" ]]; then 372 if [[ ${key} != "off" ]]; then
373 ewarn "${iface} does not support setting keys" 373 ewarn "${iface} does not support setting keys"
374 ewarn "or the parameter \"mac_key_${ESSIDVAR}\" or \"key_${ESSIDVAR}\" is incorrect" 374 ewarn "or the parameter \"mac_key_${ESSIDVAR}\" or \"key_${ESSIDVAR}\" is incorrect"
375 return 1 375 return 1
376 fi 376 fi
377 fi 377 fi
378 [[ ${key} != "off" ]] && w=$(iwconfig_get_wep_status "${iface}") 378 [[ ${key} != "off" ]] && w=$(iwconfig_get_wep_status "${iface}")
379 fi 379 fi
380 380
381 if ! iwconfig "${iface}" essid "${ESSID}" ; then 381 if ! eval iwconfig "${iface}" essid "${ESSID}" ; then
382 if [[ ${ESSID} != "any" ]]; then 382 if [[ ${ESSID} != "any" ]]; then
383 ewarn "${iface} does not support setting ESSID to \"${dessid}\"" 383 ewarn "${iface} does not support setting ESSID to \"${dessid}\""
384 fi 384 fi
385 fi 385 fi
386 386

Legend:
Removed from v.2541  
changed lines
  Added in v.2542

  ViewVC Help
Powered by ViewVC 1.1.20