By default, Bugzilla does not search the list of RESOLVED bugs.
You can force it to do so by putting the upper-case word ALL in front of your search query, e.g.: ALL tdelibs
We recommend searching for bugs this way, as you may discover that your bug has already been resolved and fixed in a later release.
Bug 828 - Incorrect "test" evaluate condition in /opt/trinity/bin/startkde startup script
Summary: Incorrect "test" evaluate condition in /opt/trinity/bin/startkde startup script
Status: RESOLVED FIXED
Alias: None
Product: TDE
Classification: Unclassified
Component: tdebase (show other bugs)
Version: 3.5.13 [Trinity]
Hardware: i386 Linux
: P5 normal
Assignee: Timothy Pearson
URL:
Depends on:
Blocks:
 
Reported: 2012-01-29 05:08 CST by yehjj
Modified: 2012-03-06 12:22 CST (History)
2 users (show)

See Also:
Compiler Version:
TDE Version String:
Application Version:
Application Name:


Attachments
Patch to fix startkde script problem (369 bytes, patch)
2012-01-29 05:08 CST, yehjj
Details | Diff
Test script (722 bytes, application/x-shellscript)
2012-01-29 05:09 CST, yehjj
Details

Note You need to log in before you can comment on or make changes to this bug.
Description yehjj 2012-01-29 05:08:14 CST
Created attachment 300 [details]
Patch to fix startkde script problem

OS: Fedora 16 i386

Issue: Due to incorrect "test" evaluate condition, startkde will always export "LD_PRELOAD" when there does not exist file "/opt/trinity//share/kgtk/preload".

Test: Using attachment's "test.sh" scripts.

Test Result by command " sh -x ./test.sh ":
-----------------------------------------------------------
+ test -n /opt/trinity/:/usr:/usr/
++ echo /opt/trinity/:/usr:/usr/
++ sed -e 's/:.*//'
+ kdedirs_first=/opt/trinity/
+ echo '[startkde] kdedirs_first: /opt/trinity/'
[startkde] kdedirs_first: /opt/trinity/
+ '[' -r /opt/trinity//share/kgtk/preload ']'
+ '[' -n ']'
+ '[' -e /usr/lib64/libnspr4.so ']'
+ '[' -e /usr/lib/libnspr4.so ']'
+ KGTK_NSPR_PRELOAD=/usr/lib/libnspr4.so:
+ export LD_PRELOAD=:/usr/lib/libnspr4.so::/usr/lib/libnspr4.so:
+ LD_PRELOAD=:/usr/lib/libnspr4.so::/usr/lib/libnspr4.so:
-----------------------------------------------------------

Then Modify "test.sh" with following patch:
--- test.sh.00  2012-01-29 18:54:59.000000000 +0800
+++ test.sh     2012-01-29 18:55:05.000000000 +0800
@@ -13,7 +13,7 @@ else
   fi
 fi

-if [ -n $KGTK_PRELOAD ]; then
+if [ -n "$KGTK_PRELOAD" ]; then
   if [ -e /usr/lib64/libnspr4.so ]; then
     KGTK_NSPR_PRELOAD="/usr/lib64/libnspr4.so:"
   elif [ -e /usr/lib/libnspr4.so ]; then

Test Result by command " sh -x ./test.sh " after patch:
-----------------------------------------------------------
+ test -n /opt/trinity/:/usr:/usr/
++ echo /opt/trinity/:/usr:/usr/
++ sed -e 's/:.*//'
+ kdedirs_first=/opt/trinity/
+ echo '[startkde] kdedirs_first: /opt/trinity/'
[startkde] kdedirs_first: /opt/trinity/
+ '[' -r /opt/trinity//share/kgtk/preload ']'
+ '[' -n '' ']'
-----------------------------------------------------------
Comment 1 yehjj 2012-01-29 05:09:27 CST
Created attachment 301 [details]
Test script
Comment 2 Darrell 2012-03-03 15:51:17 CST
Patch updated for renaming requirements and merged with other starttde fixes in attachment 458 [details] of bug report 675. Please do not merge the patch attached to this bug report.
Comment 3 Darrell 2012-03-06 12:22:07 CST
This bug report was resolved with the latest patches submitted in bug report 675.