mirror of
https://bitbucket.org/smil3y/kde-workspace.git
synced 2025-02-23 18:32:50 +00:00
ksmserver: format and indent kcheckrunning source file
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
parent
f6c5c370c8
commit
a506292cd5
1 changed files with 9 additions and 5 deletions
|
@ -24,10 +24,14 @@
|
||||||
to connect to X, 2 when it's not possible to connect to X.
|
to connect to X, 2 when it's not possible to connect to X.
|
||||||
*/
|
*/
|
||||||
int main()
|
int main()
|
||||||
{
|
{
|
||||||
Display* dpy = XOpenDisplay( NULL );
|
Display* dpy = XOpenDisplay(NULL);
|
||||||
if( dpy == NULL )
|
if (dpy == NULL) {
|
||||||
return 2;
|
return 2;
|
||||||
Atom atom = XInternAtom( dpy, "_KDE_RUNNING", False );
|
|
||||||
return XGetSelectionOwner( dpy, atom ) != None ? 0 : 1;
|
|
||||||
}
|
}
|
||||||
|
Atom atom = XInternAtom(dpy, "_KDE_RUNNING", False);
|
||||||
|
if (XGetSelectionOwner(dpy, atom) != None) {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue