Closed
Bug 148556
Opened 22 years ago
Closed 22 years ago
Crash occurs when attempting to launch Chimera when another copy is opened.
Categories
(Camino Graveyard :: General, defect)
Tracking
(Not tracked)
VERIFIED
FIXED
People
(Reporter: chrispetersen, Assigned: ccarlen)
Details
Attachments
(5 files)
2.78 KB,
patch
|
Details | Diff | Splinter Review | |
1018 bytes,
patch
|
Details | Diff | Splinter Review | |
1.36 KB,
patch
|
Details | Diff | Splinter Review | |
4.95 KB,
text/plain
|
Details | |
3.85 KB,
text/plain
|
Details |
Build: 0.3.0 (2002-06-01-05) Platform: OS X 10.1.4 Expected Results: A dialog should open stating a copy of Chimera is already opened. What I got: Application attempts to open and crashs shortly after loading splash screen. Steps to reproduce: 1) Make a copy of Chimera 2) Launch original application 3) After page displays, switch back to Finder and launch the other copy of Chimera. 4) This copy attempts to launch then crashes Date/Time: 2002-06-01 14:54:14 -0700 OS Version: 10.1.4 (Build 5Q125) Command: Navigator PID: 663 Exception: EXC_BAD_ACCESS (0x0001) Codes: KERN_PROTECTION_FAILURE (0x0002) at 0x00000000 Thread 0: #0 0x000180f8 in BookmarksService::AddObserver(void) #1 0x00024820 in -[CHBookmarksToolbar initializeToolbar] #2 0x000064e0 in -[BrowserWindowController windowDidLoad] #3 0x70da5198 in -[NSWindowController _windowDidLoad] #4 0x70c82dc4 in -[NSWindowController window] #5 0x70da5abc in -[NSWindowController showWindow:] #6 0x0000515c in -[MainController openBrowserWindowWithURL:] #7 0x000050dc in -[MainController openBrowserWindowWithURLString:] #8 0x000046e8 in -[MainController newWindow:] #9 0x00004480 in -[MainController awakeFromNib] #10 0x708a0170 in -[NSSet makeObjectsPerformSelector:] #11 0x70c17790 in -[NSIBObjectData nibInstantiateWithOwner:topLevelObjects:] #12 0x70c63830 in loadNib #13 0x70c1f050 in +[NSBundle(NSNibLoading) _loadNibFile:nameTable:withZone:ownerBundle:] #14 0x70c69a98 in +[NSBundle(NSNibLoading) loadNibFile:externalNameTable:withZone:] #15 0x70c5e014 in +[NSBundle(NSNibLoading) loadNibNamed:owner:] #16 0x70c91e74 in NSApplicationMain #17 0x00002940 in _start #18 0x00002770 in start Thread 1: #0 0x700343e8 in semaphore_wait_trap #1 0x700342c8 in pthread_join #2 0x000df214 in 0xdf214 #3 0x00000000 in 0x0 #4 0x00000000 in 0x0 Thread 2: #0 0x7003f4c8 in semaphore_wait_signal_trap #1 0x7003f2c8 in _pthread_cond_wait #2 0x70250ab0 in TSWaitOnCondition #3 0x702ae124 in MPRemoteCall #4 0x000df29c in 0xdf29c #5 0x7002054c in _pthread_body #6 0x90010008 in 0x90010008 Thread 3: #0 0x70000978 in mach_msg_overwrite_trap #1 0x70005a04 in mach_msg #2 0x70026a2c in _pthread_become_available #3 0x70026724 in pthread_exit #4 0x70848ba0 in -[NSThread _exit] #5 0x70842368 in forkThreadForFunction #6 0x7002054c in _pthread_body Thread 4: #0 0x700252fc in select #1 0x00160758 in poll #2 0x0015ce70 in _pr_poll_with_poll #3 0x022a0684 in nsSocketTransportService::Run(void) #4 0x00233800 in nsThread::Main(void *) #5 0x0015e32c in _pt_root #6 0x7002054c in _pthread_body Thread 5: #0 0x7003f4c8 in semaphore_wait_signal_trap #1 0x7003f2c8 in _pthread_cond_wait #2 0x00159418 in PR_WaitCondVar #3 0x022aa914 in nsDNSService::DequeuePendingQ(void) #4 0x022aa31c in nsDNSService::Run(void) #5 0x00233800 in nsThread::Main(void *) #6 0x0015e32c in _pt_root #7 0x7002054c in _pthread_body Thread 6: #0 0x70044cf8 in semaphore_timedwait_signal_trap #1 0x70044cd8 in semaphore_timedwait_signal #2 0x7003f2b8 in _pthread_cond_wait #3 0x001591b4 in pt_TimedWait #4 0x0015942c in PR_WaitCondVar #5 0x00237260 in TimerThread::Run(void) #6 0x00233800 in nsThread::Main(void *) #7 0x0015e32c in _pt_root #8 0x7002054c in _pthread_body Thread 7: #0 0x7003f4c8 in semaphore_wait_signal_trap #1 0x7003f2c8 in _pthread_cond_wait #2 0x00159418 in PR_WaitCondVar #3 0x00234920 in nsThreadPool::GetRequest(nsIThread *) #4 0x00235274 in nsThreadPoolRunnable::Run(void) #5 0x00233800 in nsThread::Main(void *) #6 0x0015e32c in _pt_root #7 0x7002054c in _pthread_body PPC Thread State: srr0: 0x000180f8 srr1: 0x0000f030 vrsave: 0x00000000 xer: 0x00000020 lr: 0x000180f0 ctr: 0x00268484 mq: 0x00000000 r0: 0x000180f0 r1: 0xbffff6c0 r2: 0x03a0f334 r3: 0xbffff726 r4: 0x00000000 r5: 0x00035a51 r6: 0x00000000 r7: 0x0000000d r8: 0x00000000 r9: 0x0000001a r10: 0x00268484 r11: 0x84000282 r12: 0x00268484 r13: 0x00000000 r14: 0x00000036 r15: 0x090114f0 r16: 0x09011520 r17: 0xbfffee90 r18: 0x09bbbdd0 r19: 0x0000c207 r20: 0x00000000 r21: 0x0000001c r22: 0x70004234 r23: 0x700042c8 r24: 0x00000004 r25: 0x000003a4 r26: 0x70002d84 r27: 0x70002e10 r28: 0x00000000 r29: 0xbfffef00 r30: 0x00000000 r31: 0x00000001 **********
Comment 1•22 years ago
|
||
I'll get the ball rolling on this bug with this patch. On startup, it cycles through the running processes and if it finds one with the same name (well, containing its own name) it terminates. It calls the carbon process manager. That might be bad. It didn't look like there was an equivalent thing from Cocoa. The closest thing I could think of would have involved lots of NSDistributedNotifications and various timing steps for registering/unregistering for these messages. But what the heck do I know?
Assignee | ||
Comment 3•22 years ago
|
||
Accepting. 2 instances can no longer use the same profile at the same time. nsIProfile::SetCurrentProfile() will return NS_ERROR_FILE_ACCESS_DENIED when it encounters a locked profile directory. Failure in setting a profile would lead to such a crash. The code in CHPreferenceManager.mm does not terminate the app on getting this error from SetCurrentProfile. It should. No need to check the names of other running processes.
Status: NEW → ASSIGNED
Comment 4•22 years ago
|
||
Hey. So I'm not sure if you're going to do a thorough fix (like passing back the nsresult value to the calling function & letting it respond appropriately) or you just wanted to do something like this. Oh, and if my "help" isn't particularly helpful, let me know.
Assignee | ||
Comment 5•22 years ago
|
||
Things being what they are, it's a good fix. Aside from the non-localized string. If that were fixed, I'd r= it. I find it really, really odd that NS_InitEmbedding and initialization of the profile mgr happens implicitly by initializing (of all things) prefs. If this level of initialization was moved elsewhere, it could probably be done more cleanly.
Comment 6•22 years ago
|
||
i think it was cleaner at one point, and then someone reworked the pref infrastructure and it changed. i'm not exactly sure why.
Comment 7•22 years ago
|
||
OK, it's the same as "crappy fix", but the strings are localized.
Assignee | ||
Comment 8•22 years ago
|
||
r=ccarlen on the code in the patch. The message text could use improvement. Here's the msg from Mac Mozilla for this situation: You cannot run “Mozilla 1.0.0+” while another copy of Mozilla or Netscape 6 is running. “Mozilla 1.0.0+” will now quit. So, changing the names... You cannot run “Navigator” while another copy is running. “Navigator” will now quit.
Comment 9•22 years ago
|
||
tweaked the text more after talking to conrad.
Status: ASSIGNED → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
Comment 10•22 years ago
|
||
ok, i put the localized string file into the English.lproj dir, but i have no idea how to correctly hook it up. the project freaks out when i add it. I can't make it behave like the InfoPlist.strings. ideas? (i checked in the unlocalized version so at least people will stop crashing...i hate being behind on my bugmail...sigh)
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Comment 11•22 years ago
|
||
Well, here's how I added Localizable.strings to my project. I have no idea how it freaked out, so I'll try to be specific. If you did this already, well, beats me. 1. Put Localizable.strings someplace on my disk. 2. In PB, Project Menu -> Add Files. Pick the Localizable.strings file. I selected both the Navigator & Navigator.static builds. Clicked OK. I think I took the defaults for everything else. 3. In PB, clicked on the Localizable.strings file. Project Menu -> Show Info. In the Localizations & Platforms combo box, picked "Add Localized Variant" Picked "English" from the dialog box. 4. There is no step 4. PB handled moving Localizable.strings into the in mozilla/chimera/English.lproj. The next time I built Navigator, things just worked.
Comment 12•22 years ago
|
||
sweet. i chose "make localized" which horked the entire project. thanks!
Status: REOPENED → RESOLVED
Closed: 22 years ago → 22 years ago
Resolution: --- → FIXED
Reporter | ||
Comment 13•22 years ago
|
||
Marking verified in the NB 2002-06-19-05 build.
Status: RESOLVED → VERIFIED
Comment 14•22 years ago
|
||
Reopening bug... Regression? 1. Set default web browser in System Preferences to another Chimera build from earlier this week (or last week). 2. Have the 06-21 build running on OS 10.1.5. 3. Click on a URL in my Inbox in Mail. Expected result: another copy of Chimera opens successfully. Actual results: - It attempts to open that default web browser, i.e. an older chimera build. - Splash screen is displayed. - Dialog box pops up saying "Cannot launch Navigator. Another copy of Navigator is already running." - Dialog box disappears after 2 seconds or so. - Another dialog box shows "This application has unexpectedly quit." - 06-21 Chimera copy is still running fine without a problem after this crash. I can load new pages.
Comment 16•22 years ago
|
||
Second test: 1. Have the 06-21 build running on OS 10.1.5. 2. Launch an older copy of Chimera from earlier this week or last week directly without using helper apps. Expected result: That older copy of chimera launches successfully. Actual result: "This application has unexpectedly quit."
Comment 17•22 years ago
|
||
Marking Fixed. Just realized that my comments 14, 15, 16 had to do with testing using a combination of chimera builds with the fix and without the fix. Tested with newer builds (06-21 and 06-24) builds and the fix works just fine.
Status: REOPENED → RESOLVED
Closed: 22 years ago → 22 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•