Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

PATCH: Coverity CID 1500747 0-initialize ti



This isn't strictly necessary but it's done a few lines above for the -s
branch so it's at least consistent if we do the same thing in both
places.
---
 Src/builtin.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Src/builtin.c b/Src/builtin.c
index 266fcf9248..7061918325 100644
--- a/Src/builtin.c
+++ b/Src/builtin.c
@@ -6572,6 +6572,7 @@ bin_read(char *name, char **args, Options ops, UNUSED(int func))
 #endif
 	if (isatty(readfd)) {
 	    struct ttyinfo ti;
+	    memset(&ti, 0, sizeof(struct ttyinfo));
 	    fdgettyinfo(readfd, &ti);
 	    if (! resettty) {
 	      saveti = ti;
-- 
2.38.1





Messages sorted by: Reverse Date, Date, Thread, Author