[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-1663?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13661808#comment-13661808
 ] 

Amichai Rothman commented on ZOOKEEPER-1663:
--------------------------------------------

I submitted two patches, one with the .trunk.patch extension which applies 
against trunk, and one with only .patch extension which applies against 3.4.5 
and also (I just tried it) the 3.4 branch.

btw I just found another bug, both in the original script and updated one (on 
both trunk and branch) - in zkEnv.sh line ~94, both

{noformat} if [ -e "${ZOOKEEPER_PREFIX}/share/zookeeper/zookeeper-*.jar" ]; 
then {noformat}

and

{noformat} if [ -e "${ZOOKEEPER_PREFIX}"/share/zookeeper/zookeeper-*.jar ]; 
then {noformat}

don't work correctly - the former doesn't expand the wildcard, and the latter 
expands to multiple arguments which causes test to fail.
The correct way to do this appears to be

{noformat} if ls "${ZOOKEEPER_PREFIX}"/share/zookeeper/zookeeper-*.jar > 
/dev/null 2>&1; then {noformat}

                
> scripts don't work when path contains spaces
> --------------------------------------------
>
>                 Key: ZOOKEEPER-1663
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-1663
>             Project: ZooKeeper
>          Issue Type: Bug
>          Components: scripts
>    Affects Versions: 3.4.5
>         Environment: Kubuntu 12.10 (GNU bash 4.2.37)
>            Reporter: Amichai Rothman
>            Assignee: Amichai Ungar
>            Priority: Minor
>             Fix For: 3.5.0, 3.4.6
>
>         Attachments: ZOOKEEPER-1663.patch, ZOOKEEPER-1663.trunk.patch, 
> ZOOKEEPER-1663.trunk.patch
>
>
> The shell scripts (bin/zk*.sh) don't work when there are spaces in the 
> zookeeper or java paths.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to