-
-
Notifications
You must be signed in to change notification settings - Fork 221
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add a function which returns the number of running instances #89
Comments
Just read the source codes, it seems that what I need is UPD: No, |
This function returns the number of running instances, by add a new variable in InstancesInfo. This feature is asked in itay-grudev#89.
This function returns the number of running instances, by adding a new variable in InstancesInfo. This closes itay-grudev#89.
Yhea. |
The function: bool SingleApplication::isSingleInstance() Returns if the instance is the only running instance. It was hard to check the number of running instances after a crash, so this is an alternative solution for itay-grudev#89. It uses a trick: the shared memory will be released after the last instance detaches from it.
The function: bool SingleApplication::isSingleInstance() Returns if the instance is the only running instance. It is hard to check the number of running instances after a crash, so this is an alternative solution for itay-grudev#89. It uses a trick: the shared memory will be released after the last instance detaches from it.
Here's a solution: But I'm not familiar with it, I hope someone else could implement it, thanks in advance! |
@ouuan I really appreciate your effort. When I have some more free time I will consider implementing it, but it may be a while as my schedule is really packed right now. |
Feature request: Add a function which returns the number of running instances. (In fact, I only want to know if one instance is the only running instance.)
This is helpful if you want to behave differently on different number of instances.
My actual need is described in cpeditor/cpeditor#131, if you are interested in where this feature is useful.
The text was updated successfully, but these errors were encountered: