]> andersk Git - moira.git/blobdiff - clients/moira/menu.c
strncpy doesn't always NULL terminate. Fixes display bug in long lines
[moira.git] / clients / moira / menu.c
index 6c0ae53fc23bd50f5487ded3723adb36e37b8573..d18884e3c749371dca82ba7a2ff18ec494d543e8 100644 (file)
@@ -679,6 +679,7 @@ char *msg;
     while(*s++) {
        if (s - line >= COLS-1) {
            (void) strncpy(copy, line, COLS-1);
+           copy[COLS-1] = '\0';
            line += COLS-1;
        } else if (*s == '\n') {
            *s = '\0';
This page took 0.051616 seconds and 4 git commands to generate.