Closed
Bug 340424
Opened 18 years ago
Closed 18 years ago
XPFE - nsCommandLineService isn't "reusable"
Categories
(Core :: General, defect)
Tracking
()
RESOLVED
WONTFIX
People
(Reporter: sergei_d, Unassigned)
References
()
Details
nsCmdLineService::Initialize(int aArgc, char ** aArgv) method actually "initializes" only mArgc/mArgv but not mArgList and mArgValueList http://lxr.mozilla.org/seamonkey/source/xpfe/components/startup/src/nsCommandLineService.cpp#115 It just adds new values to end of lists. So, if someone decides to use this component to handle "remote/run-time" calls with argc/argv and use same instance of nsCommandLineService - all following service calls (like GetURLToLoad()) will return values based on very first argc/argv. Wondering if it was comonent author's intention. Actually, problem could be solved very easy with adding mArgList.Clear() and mArgValueList.Clear() after <a href="http://lxr.mozilla.org/seamonkey/source/xpfe/components/startup/src/nsCommandLineService.cpp#114">line 114</a>. And i think this is just hot this method should work. Yeah, everyone can rewrite and double that whole nsCommandLineService functionality for own platform, like Windows and OS/2 do - but is it good thing if we have already such thing implemented? P.S. Unsure if XP Miscellany is best place, but didn't find more suitable
Comment 1•18 years ago
|
||
The XPFE commandline service is going away, let's not try to fix this.
Status: NEW → RESOLVED
Closed: 18 years ago
Resolution: --- → WONTFIX
Reporter | ||
Comment 2•18 years ago
|
||
benjamin, and what about SM branch?
Comment 3•18 years ago
|
||
Which branch? I don't think we want to mess with these interfaces/impls on the 1.8 or 1.8.0 branches.
You need to log in
before you can comment on or make changes to this bug.
Description
•