Closed Bug 263485 Opened 20 years ago Closed 19 years ago

firefox command line script aborts if parameters contain whitespace (blanks)

Categories

(Firefox :: General, defect)

Sun
SunOS
defect
Not set
normal

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: shamus.mcbride, Assigned: bugzilla)

Details

User-Agent:       Mozilla/5.0 (X11; U; SunOS sun4u; rv:1.7.3) Gecko/20040916 Firefox/0.10
Build Identifier: Mozilla/5.0 (X11; U; SunOS sun4u; rv:1.7.3) Gecko/20040916 Firefox/0.10

firefox script aborts with 'test: unknown operator' if parameter contains
blanks. The problem is missing quotes around shell variables in relative new
code that sifts through arguments looking for a url.

Reproducible: Always
Steps to Reproduce:
1. firefox -xrm '*workspaceList: ws0 ws12' http://www.mozilla.org
(I know the -xrm argument is never honored, but it used to get passed down the
line).
Actual Results:  
firefox -xrm '*workspaceList: ws0 ws12' http://www.mozilla.org
+ firefox -xrm *workspaceList: ws0 ws12 http://www.mozilla.org
/home/tecslm1/bin/aps/firefox/firefox: test: unknown operator ws0
--- and in detail:
for i in "$@"; do
        [ $i = ${_optLast} ] && break
        _optOthers="${_optOthers} ${i}"
done #others arg
+ [ -xrm = http://www.mozilla.org ]
_optOthers= -xrm
+ [ *workspaceList: ws0 ws12 = http://www.mozilla.org ]
/home/tecslm1/bin/aps/firefox/firefox: test: unknown operator ws0

Expected Results:  
Passed my arguments to run-mozilla.sh as it used to.

I verified problem still exists in linux nightly build retrieved 8 October 2004.

This fixes the problem:

diff -cr firefox/firefox firefox-fixed/firefox
*** firefox/firefox     Thu Sep 16 18:57:51 2004
--- firefox-fixed/firefox       Thu Sep 30 07:26:25 2004
***************
*** 163,169 ****
  done #last arg

  for i in "$@"; do
!       [ $i = ${_optLast} ] && break
        _optOthers="${_optOthers} ${i}"
  done #others arg

--- 163,169 ----
  done #last arg

  for i in "$@"; do
!       [ "$i" = "${_optLast}" ] && break
        _optOthers="${_optOthers} ${i}"
  done #others arg
This is an automated message, with ID "auto-resolve01".

This bug has had no comments for a long time. Statistically, we have found that
bug reports that have not been confirmed by a second user after three months are
highly unlikely to be the source of a fix to the code.

While your input is very important to us, our resources are limited and so we
are asking for your help in focussing our efforts. If you can still reproduce
this problem in the latest version of the product (see below for how to obtain a
copy) or, for feature requests, if it's not present in the latest version and
you still believe we should implement it, please visit the URL of this bug
(given at the top of this mail) and add a comment to that effect, giving more
reproduction information if you have it.

If it is not a problem any longer, you need take no action. If this bug is not
changed in any way in the next two weeks, it will be automatically resolved.
Thank you for your help in this matter.

The latest beta releases can be obtained from:
Firefox:     http://www.mozilla.org/projects/firefox/
Thunderbird: http://www.mozilla.org/products/thunderbird/releases/1.5beta1.html
Seamonkey:   http://www.mozilla.org/projects/seamonkey/
SLM: The logic in the "firefox" script has been reworked at some point so the
bug is nolonger present. 
Status: UNCONFIRMED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Status: RESOLVED → UNCONFIRMED
Resolution: FIXED → ---
We don't know what fixed this worksforme
Status: UNCONFIRMED → RESOLVED
Closed: 19 years ago19 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.