Introduction
Introduction Statistics Contact Development Disclaimer Help
Use NUL character constant explicitly - slock - simple X display locker utility
git clone git://git.suckless.org/slock
Log
Files
Refs
README
LICENSE
---
commit b099d2fd1868a5497069b85e5af0e6148077a6ba
parent 0a43b78d00ebac574376ffd93223a751e21e265e
Author: FRIGN <[email protected]>
Date: Sat, 1 Oct 2016 23:56:33 +0200
Use NUL character constant explicitly
Diffstat:
M slock.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/slock.c b/slock.c
@@ -158,7 +158,7 @@ readpw(Display *dpy, struct xrandr *rr, struct lock **locks…
continue;
switch (ksym) {
case XK_Return:
- passwd[len] = 0;
+ passwd[len] = '\0';
errno = 0;
if (!(inputhash = crypt(passwd, hash)))
fprintf(stderr, "slock: crypt: %s\n", …
@@ -177,7 +177,7 @@ readpw(Display *dpy, struct xrandr *rr, struct lock **locks…
break;
case XK_BackSpace:
if (len)
- passwd[len--] = 0;
+ passwd[len--] = '\0';
break;
default:
if (num && !iscntrl((int)buf[0]) &&
You are viewing proxied material from suckless.org. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.