|
|
@ -150,8 +150,6 @@ main(int argc, char **argv) { |
|
|
|
Display *dpy; |
|
|
|
Display *dpy; |
|
|
|
Screen *screen; |
|
|
|
Screen *screen; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (setuid(0)) |
|
|
|
if (setuid(0)) |
|
|
|
die("setuid(0) failed\n"); |
|
|
|
die("setuid(0) failed\n"); |
|
|
|
if (!(dpy = XOpenDisplay(NULL))) |
|
|
|
if (!(dpy = XOpenDisplay(NULL))) |
|
|
@ -160,9 +158,8 @@ main(int argc, char **argv) { |
|
|
|
screen = XDefaultScreen(dpy); |
|
|
|
screen = XDefaultScreen(dpy); |
|
|
|
XSync(dpy, 0); |
|
|
|
XSync(dpy, 0); |
|
|
|
getoldbrightness(); |
|
|
|
getoldbrightness(); |
|
|
|
updatescreenon(1); |
|
|
|
|
|
|
|
lockscreen(dpy, screen); |
|
|
|
lockscreen(dpy, screen); |
|
|
|
XSync(dpy, 0); |
|
|
|
updatescreenon(1); |
|
|
|
readinputloop(dpy, screen); |
|
|
|
readinputloop(dpy, screen); |
|
|
|
return 0; |
|
|
|
return 0; |
|
|
|
} |
|
|
|
} |
|
|
|