[Interest] Detecting if the application is already running from another user account

Thiago Macieira thiago.macieira at intel.com
Fri Jun 3 15:08:10 CEST 2016


On sexta-feira, 3 de junho de 2016 11:40:31 BRT Etienne Sandré-Chardonnal 
wrote:
> Hi,
> 
> I would like to detect if my application is already running from another
> user account and warn the user.

Create a file in a public place (like /tmp) that indicates it's running. You 
can use a QLockFile, provided the other side always uses tryLock() and never 
lock().

-- 
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center




More information about the Interest mailing list