Introduction
Introduction Statistics Contact Development Disclaimer Help
tapplied Jukka's patch preventing some cornercases and making the EOF error mes…
git clone git://src.adamsgaard.dk/dwm
Log
Files
Refs
README
LICENSE
---
commit 35e96b8deba8aae863cef32f2ea2a84ebf162472
parent 2210ea7e3b0b2839ac7fb49c18d2731cb9e94e01
Author: arg@mig29 <unknown>
Date: Mon, 27 Nov 2006 10:29:47 +0100
applied Jukka's patch preventing some cornercases and making the EOF error mess…
Diffstat:
M main.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/main.c b/main.c
t@@ -277,10 +277,11 @@ main(int argc, char *argv[]) {
switch(r = read(STDIN_FILENO, stext, sizeof stext - 1)…
case -1:
strncpy(stext, strerror(errno), sizeof stext -…
+ stext[sizeof stext - 1] = '\0';
readin = False;
break;
case 0:
- strncpy(stext, "EOF", sizeof stext);
+ strncpy(stext, "EOF", 4);
readin = False;
break;
default:
You are viewing proxied material from mx1.adamsgaard.dk. 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.