Searched +hist:4 +hist:e51dee8 (Results 1 - 1 of 1) sorted by relevance

/haiku/src/kits/app/
H A DApplication.cppdiff 6bfd06d1 Thu Aug 31 11:54:16 MDT 2006 Ingo Weinhold <ingo_weinhold@gmx.de> BRoster::Launch() eventually launches the application in question
in several steps:
1. early pre-registration with the registrar ("I wanna launch the
app, make sure noone interferes.")
2. load the app image
3. finish pre-registration with the registrar ("I have launched
the app, here is its team ID.")
4. start app main thread
5. send "on launch" messages to the app (argv, refs, others)

If the app is already running or being launched, 1. fails with a
conclusive error code and returns the team ID and the pre-registration
token of the app. Steps 2 - 4 are skipped and only the messages are
delivered using the team ID returned by 1.

This change fixes a race condition: The failed early pre-registration
request obviously cannot return the team ID, if the other thread
launching the app has not finished step 3 yet. Thus the argv/refs
message would not get delivered and Launch() would not return the
correct team ID.

Now we wait for the pre-registration to be finished in this case, using
the former _IsAppPreRegistered() mechanism, which already provided
such a waiting feature for one request. It has been extended to
accomodate an arbitrary number of waiting requests and renamed to
_IsAppRegistered().

This fixed bug #763.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18728 a95241bf-73f2-0310-859d-f6bbb57e9c96
diff 6bfd06d1 Thu Aug 31 11:54:16 MDT 2006 Ingo Weinhold <ingo_weinhold@gmx.de> BRoster::Launch() eventually launches the application in question
in several steps:
1. early pre-registration with the registrar ("I wanna launch the
app, make sure noone interferes.")
2. load the app image
3. finish pre-registration with the registrar ("I have launched
the app, here is its team ID.")
4. start app main thread
5. send "on launch" messages to the app (argv, refs, others)

If the app is already running or being launched, 1. fails with a
conclusive error code and returns the team ID and the pre-registration
token of the app. Steps 2 - 4 are skipped and only the messages are
delivered using the team ID returned by 1.

This change fixes a race condition: The failed early pre-registration
request obviously cannot return the team ID, if the other thread
launching the app has not finished step 3 yet. Thus the argv/refs
message would not get delivered and Launch() would not return the
correct team ID.

Now we wait for the pre-registration to be finished in this case, using
the former _IsAppPreRegistered() mechanism, which already provided
such a waiting feature for one request. It has been extended to
accomodate an arbitrary number of waiting requests and renamed to
_IsAppRegistered().

This fixed bug #763.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18728 a95241bf-73f2-0310-859d-f6bbb57e9c96
diff 4c3e1ace Tue Jul 05 22:48:22 MDT 2005 Axel Dörfler <axeld@pinc-software.de> Fixed a bug in quit_all_windows(): we need to Unlock() the application
because BWindow::QuitRequested() must be allowed to lock it.
This fixes a deadlock when trying to quit Tracker.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13479 a95241bf-73f2-0310-859d-f6bbb57e9c96
diff 4e51dee8 Wed Jan 19 08:35:49 MST 2005 DarkWyrm <darkwyrm@gmail.com> don't prevent ReadyToRun from being called when running without the registrar


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10877 a95241bf-73f2-0310-859d-f6bbb57e9c96
diff 4e51dee8 Wed Jan 19 08:35:49 MST 2005 DarkWyrm <darkwyrm@gmail.com> don't prevent ReadyToRun from being called when running without the registrar


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10877 a95241bf-73f2-0310-859d-f6bbb57e9c96
diff 4a87ab98 Tue Aug 13 16:38:24 MDT 2002 Ingo Weinhold <ingo_weinhold@gmx.de> Set the the application BHandler's name correctly.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@754 a95241bf-73f2-0310-859d-f6bbb57e9c96
diff 6bfd06d1ff129f4db4445b978fa3ee9257f239c9 Thu Aug 31 11:54:16 MDT 2006 Ingo Weinhold <ingo_weinhold@gmx.de> BRoster::Launch() eventually launches the application in question
in several steps:
1. early pre-registration with the registrar ("I wanna launch the
app, make sure noone interferes.")
2. load the app image
3. finish pre-registration with the registrar ("I have launched
the app, here is its team ID.")
4. start app main thread
5. send "on launch" messages to the app (argv, refs, others)

If the app is already running or being launched, 1. fails with a
conclusive error code and returns the team ID and the pre-registration
token of the app. Steps 2 - 4 are skipped and only the messages are
delivered using the team ID returned by 1.

This change fixes a race condition: The failed early pre-registration
request obviously cannot return the team ID, if the other thread
launching the app has not finished step 3 yet. Thus the argv/refs
message would not get delivered and Launch() would not return the
correct team ID.

Now we wait for the pre-registration to be finished in this case, using
the former _IsAppPreRegistered() mechanism, which already provided
such a waiting feature for one request. It has been extended to
accomodate an arbitrary number of waiting requests and renamed to
_IsAppRegistered().

This fixed bug #763.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18728 a95241bf-73f2-0310-859d-f6bbb57e9c96
diff 6bfd06d1ff129f4db4445b978fa3ee9257f239c9 Thu Aug 31 11:54:16 MDT 2006 Ingo Weinhold <ingo_weinhold@gmx.de> BRoster::Launch() eventually launches the application in question
in several steps:
1. early pre-registration with the registrar ("I wanna launch the
app, make sure noone interferes.")
2. load the app image
3. finish pre-registration with the registrar ("I have launched
the app, here is its team ID.")
4. start app main thread
5. send "on launch" messages to the app (argv, refs, others)

If the app is already running or being launched, 1. fails with a
conclusive error code and returns the team ID and the pre-registration
token of the app. Steps 2 - 4 are skipped and only the messages are
delivered using the team ID returned by 1.

This change fixes a race condition: The failed early pre-registration
request obviously cannot return the team ID, if the other thread
launching the app has not finished step 3 yet. Thus the argv/refs
message would not get delivered and Launch() would not return the
correct team ID.

Now we wait for the pre-registration to be finished in this case, using
the former _IsAppPreRegistered() mechanism, which already provided
such a waiting feature for one request. It has been extended to
accomodate an arbitrary number of waiting requests and renamed to
_IsAppRegistered().

This fixed bug #763.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18728 a95241bf-73f2-0310-859d-f6bbb57e9c96
diff 4c3e1ace67353f5f1b9cc63844b40512be710e73 Tue Jul 05 22:48:22 MDT 2005 Axel Dörfler <axeld@pinc-software.de> Fixed a bug in quit_all_windows(): we need to Unlock() the application
because BWindow::QuitRequested() must be allowed to lock it.
This fixes a deadlock when trying to quit Tracker.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13479 a95241bf-73f2-0310-859d-f6bbb57e9c96
diff 4e51dee8d03b60864ce1c33118d65c5d63613a5a Wed Jan 19 08:35:49 MST 2005 DarkWyrm <darkwyrm@gmail.com> don't prevent ReadyToRun from being called when running without the registrar


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10877 a95241bf-73f2-0310-859d-f6bbb57e9c96

Completed in 165 milliseconds