Notice: Trying to access array offset on value of type bool in /srv/www/vhosts/openpandora.org/domains/bugs.openpandora.org/httpdocs/scripts/details.php on line 649 FS#233 : op_power.sh: errors

OpenPandora Main OS

  • Status Closed
  • Percent Complete
    100%
  • Task Type Bug Report
  • Category Core
  • Operating System Release 1 (Zaxxon)
  • Severity Very Low
  • Reported Version Hotfix 5
Attached to Project: OpenPandora Main OS
Opened by T4b - 21.06.2011
Last edited by Michael Mrozek - 12.11.2011

FS#233 - op_power.sh: errors

op_power.sh gives some errors to me... it works anyway, but it's not nice to see them all the time. /usr/pandora/scripts/op_power.sh: line 60: [: 5380: binary operator expected or /usr/pandora/scripts/op_power.sh: line 60: [: too many arguments I guess line 60 of op_power.sh if [ ! $wlstate ]; then should rather be if [ -z "$wlstate" ]; then shouldn't it? The same thing is in line Then sometimes also rm: cannot remove `/tmp/wlstate': No such file or directory or cat: /tmp/wlstate: No such file or directory which could easily be fixed by adding a test -f /tmp/wlstate && or something like that before the respective command. I just added a lot of test, I'm not sure if every single one of them is really needed, but better too much than not enough, I would say. :-) I can't attach a file (I click the button and nothing happens), so I just paste it there: http://nopaste.info/2256365eba.html It's a bit longer because some indentations were wrong (and I corrected them) and I changed all indentations to tabs = 8 spaces instead of 2.
Closed by  Michael Mrozek
12.11.2011 01:34
Reason for closing:  Fixed
T4b commented on 21.06.2011 16:42
Oops, have got some half finished sentece in the bug report "The same thing is in line" should continue with "27 and 31."
Johannes Geiss commented on 24.10.2011 11:49
I can confirm this. The recommended fix removes the error messages.

Loading...

Available keyboard shortcuts

Tasklist

Task Details

Task Editing