Closed Bug 395661 Opened 17 years ago Closed 12 years ago

XULRunner restart fails if path to application.ini is relative

Categories

(Toolkit Graveyard :: XULRunner, defect)

x86
Windows XP
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WORKSFORME

People

(Reporter: jwkbugzilla, Assigned: jwkbugzilla)

References

Details

Attachments

(1 file, 1 obsolete file)

I start a XULRunner application: xulrunner/xulrunner.exe xul/application.ini Somewhere in the application a restart is triggered: Components.classes["@mozilla.org/toolkit/app-startup;1"].getService(nsIAppStartup) .quit(nsIAppStartup.eAttemptQuit | nsIAppStartup.eRestart); On restart I see the message "Error: couldn't parse application.ini". Reason is that the current directory changed, relative application.ini path is resolved to xulrunner/xul/application.ini. I see two possible solutions: 1. Don't store relative paths, save the path after resolution of relative paths instead. 2. Save current directory and restore is when application is restarted. The first should be easier to implement while the second is a more general solution for this kind of issues.
Attached patch Proposed patch (obsolete) — Splinter Review
This patch implements the first alternative. Please tell me if you think that we need a more general approach here.
Assignee: nobody → trev.moz
Status: NEW → ASSIGNED
Attachment #280338 - Flags: review?
Attachment #280338 - Flags: review? → review?(benjamin)
For consistency, should the absolute path code be added here too? http://mxr.mozilla.org/seamonkey/source/browser/app/nsBrowserApp.cpp#139
You are right, we need to change browser as well.
Attachment #280338 - Attachment is obsolete: true
Attachment #280339 - Flags: review?(benjamin)
Attachment #280338 - Flags: review?(benjamin)
FYI: the potential fix for bug 386826 will collide with this patch
Yes, I am aware of that.
Comment on attachment 280339 [details] [diff] [review] Proposed patch v2 According to Roland Boon, his patch in bug 386826 fixes this issue as well.
Attachment #280339 - Flags: review?(benjamin)
Depends on: 386826
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → WORKSFORME
Product: Toolkit → Toolkit Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: