/etc/acpi/wireless.sh unwanted behaviours

Bug #66082 reported by Nicolò Chieffo
2
Affects Status Importance Assigned to Milestone
acpi-support (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

Hello, I was looking at the code in /etc/wireless.sh. I found a big problem in two cases
1) the user doesn't have a wireless device
2) the user has got more than one wireless device

in the former case wireless.sh does not return anything (in my opinion it should return 0). So my laptop has a wireless hotkey and a wireless led but not a wireless device (I bought it because it was cheaper). So when I hit the hotkey the led comes up, because wireless.sh does not return 0!

the latter case is more complicated. For instance immagine that the user has 2 wireless devices. one integrated and one external (he bought the external one because it was faster). whenever he hits the hotkey, wireless.sh will begin the "for" cycle and find the first wireless card: it will switch off the device and echo "0" (+ \n). Then the for goes into the second device and does the same thing. the result is:
0
0

and both cards are off. what about the led?? it's on! because wireless.sh should have returned 0, not 0\n0!

NOTE: the led is handled by /etc/acpi/asus-wireless.sh

And... What will happen if one card is on and the other is off???

I will attach a new proposed wireless.sh.

Revision history for this message
Nicolò Chieffo (yelo3) wrote :

this might be a good replacement, let me know

Revision history for this message
Nicolò Chieffo (yelo3) wrote :

another bug: wireless.sh does not check if the action he does results in an error. So it will echo 0 even if the shutdown has failed!

Revision history for this message
Nicolò Chieffo (yelo3) wrote :

deprecated use. wireless.sh should be completely rewritten since linux-2.6.20 does no more handle this way to control the wlan

Changed in acpi-support:
status: Unconfirmed → Rejected
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.