THIS IS AN AUTOMATED MESSAGE, DO NOT REPLY.
The following task is now closed:
FS#332 - op_lidsettings.sh and op_power.sh scripts fail for some usernames
User who did this - Grazvydas (notaz)
Reason for closing: Fixed
Additional comments about closing: applied
More information can be found at the following URL:
http://bugs.openpandora.org/index.php?do=details&task_id=332
You are receiving this message because you have requested it from the Flyspray bugtracking system. If you did not expect this message or don't want to receive mails in future, you can change your notification settings at the URL shown above.
THIS IS AN AUTOMATED MESSAGE, DO NOT REPLY.
The following task has a new comment added:
FS#332 - op_lidsettings.sh and op_power.sh scripts fail for some usernames
User who did this - Grazvydas (notaz)
----------
<p>It doesn't look like we have active firmware developers to fix this, but if you could prepare a patch or fixed versions of the scripts, I could apply them for next update.</p>
----------
More information can be found at the following URL:
http://bugs.openpandora.org/index.php?do=details&task_id=332#comment535
You are receiving this message because you have requested it from the Flyspray bugtracking system. If you did not expect this message or don't want to receive mails in future, you can change your notification settings at the URL shown above.
THIS IS AN AUTOMATED MESSAGE, DO NOT REPLY.
A new Flyspray task has been opened. Details are below.
User who did this - russ (russ)
Attached to Project - OpenPandora Main OS
Summary - op_lidsettings.sh and op_power.sh scripts fail for some usernames
Task Type - Bug Report
Category - Core
Status - Unconfirmed
Assigned To -
Operating System - Release 1 (Zaxxon)
Severity - Medium
Priority - Very Low
Reported Version - SuperZaxxon Final 1.54
Due in Version - Undecided
Due Date - Undecided
Details - <p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';">/usr/pandora/scripts/op_lidsettings.sh and <span style="font-family: 'Source Code Pro'; font-size: 12px; line-height: normal;">/usr/pandora/scripts/</span>op_power.sh fail for some usernames due to poor shell scripting</p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';"> </p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';">these scripts find their config files by grepping /etc/passwd for the uer currently running xfce4-session, but the loose regexp matches too much. this shell fragment from op_lidsettings.sh:</p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';"> </p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';">grep /etc/passwd -e $(ps u -C xfce4-session | tail -n1 | awk '{print $1}')| cut -f 6 -d ":"</p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';"> </p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';">when a use called "me" is logged in, returns</p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';"> </p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';">/home/root</p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';">/usr/games</p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';">/var/run/dbus</p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';">/home/me</p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';"> </p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';">rather than just "/home/me"</p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';"> </p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';">all instances of that construct (reading and writing settings, in both op_lidsettings.sh and op_power.sh) should be changed to</p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';"> </p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';"><span style="font-family: 'Source Code Pro'; font-size: 12px; line-height: normal;">grep /etc/passwd -e ^$(ps u -C xfce4-session | tail -n1 | awk '{print $1}'): | cut -f 6 -d ":"</span></p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';"> </p>
<p style="margin: 0px; font-size: 12px; line-height: normal; font-family: 'Source Code Pro';"><span style="font-family: 'Source Code Pro'; font-size: 12px; line-height: normal;">to correctly match only the complete username field in /etc/passwd</span></p>
More information can be found at the following URL:
http://bugs.openpandora.org/index.php?do=details&task_id=332
You are receiving this message because you have requested it from the Flyspray bugtracking system. If you did not expect this message or don't want to receive mails in future, you can change your notification settings at the URL shown above.