From ffe739eeb12d1bf9dadb2144e95fef79820c6844 Mon Sep 17 00:00:00 2001 From: Jeffrey Armstrong Date: Tue, 7 Jan 2014 20:27:07 -0500 Subject: Fixed possible unterminated strings in hash handling in commit code. --- prism.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'prism.c') diff --git a/prism.c b/prism.c index bd18ae9..7d19cb8 100644 --- a/prism.c +++ b/prism.c @@ -56,7 +56,7 @@ static void init_task() static void add_task(const char *filename) { -char new_hash[33]; +char new_hash[HASH_BYTES]; int res; struct db_file oldfile; @@ -130,9 +130,9 @@ int res; static void hash_task(const char *filename) { int res; -char hash[33]; +char hash[HASH_BYTES]; - memset(hash, 0, 33); + memset(hash, 0, HASH_BYTES); printf("Computing hash for %s...\n", filename); res = get_file_hash(filename, hash); -- cgit v1.2.3