diff options
author | Amadeusz Sławiński <amade@asmblr.net> | 2018-04-06 11:22:26 +0200 |
---|---|---|
committer | Amadeusz Sławiński <amade@asmblr.net> | 2018-04-07 13:29:11 +0200 |
commit | 60e19ab26ebbc925485daf5c932de66d557c3f88 (patch) | |
tree | 5bba55ae324e233aba4aeb4d7b95bb4e66228748 /src/tty.c | |
parent | 12aed9c422ac7c4e83e353f2a4437e0532311e82 (diff) | |
download | screen-60e19ab26ebbc925485daf5c932de66d557c3f88.tar.gz |
get rid of (sometype *)0 casts
using NULL makes it clear enough what's going on
Diffstat (limited to 'src/tty.c')
-rw-r--r-- | src/tty.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -124,7 +124,7 @@ int OpenTTY(char *line, char *opt) */ #ifdef TIOCEXCL errno = 0; - if (ioctl(f, TIOCEXCL, (char *)0) < 0) + if (ioctl(f, TIOCEXCL, NULL) < 0) Msg(errno, "%s: ioctl TIOCEXCL failed", line); #endif /* TIOCEXCL */ /* @@ -658,7 +658,7 @@ static void DoSendBreak(int fd, int n, int type) * perform long breaks. But for SOLARIS, this is not true, of course. */ for (int i = 0; i < n; i++) - if (ioctl(fd, TCSBRK, (char *)0) < 0) { + if (ioctl(fd, TCSBRK, NULL) < 0) { Msg(errno, "Cannot send BREAK (TCSBRK)"); return; } @@ -673,12 +673,12 @@ static void DoSendBreak(int fd, int n, int type) * This is very rude. Screen actively celebrates the break. * But it may be the only save way to issue long breaks. */ - if (ioctl(fd, TIOCSBRK, (char *)0) < 0) { + if (ioctl(fd, TIOCSBRK, NULL) < 0) { Msg(errno, "Can't send BREAK (TIOCSBRK)"); return; } usleep(1000 * (n ? n * 250 : 250)); - if (ioctl(fd, TIOCCBRK, (char *)0) < 0) { + if (ioctl(fd, TIOCCBRK, NULL) < 0) { Msg(errno, "BREAK stuck!!! -- HELP! (TIOCCBRK)"); return; } |