[nasm:master] rdoff: search_libraries - zeroify stack allocated structure
nasm-bot for Cyrill Gorcunov
gorcunov at gmail.com
Sun Oct 4 13:39:11 PDT 2020
Commit-ID: 858bc9d6b9d8d77961a375e792e69666d613383f
Gitweb: http://repo.or.cz/w/nasm.git?a=commitdiff;h=858bc9d6b9d8d77961a375e792e69666d613383f
Author: Cyrill Gorcunov <gorcunov at gmail.com>
AuthorDate: Sun, 4 Oct 2020 23:35:55 +0300
Committer: Cyrill Gorcunov <gorcunov at gmail.com>
CommitDate: Sun, 4 Oct 2020 23:35:55 +0300
rdoff: search_libraries - zeroify stack allocated structure
Coverity scan tool complains on rdffile::rdoff_ver member
being called with memcpy uninitialized. Lets zap this
structure explicitly once we've it allocated.
CID 1432931
Signed-off-by: Cyrill Gorcunov <gorcunov at gmail.com>
---
rdoff/ldrdf.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/rdoff/ldrdf.c b/rdoff/ldrdf.c
index a78c4504..a3b0dac0 100644
--- a/rdoff/ldrdf.c
+++ b/rdoff/ldrdf.c
@@ -606,6 +606,7 @@ static int search_libraries(void)
cur = libraries;
+ memset(&f, 0, sizeof(f));
while (cur) {
if (options.verbose > 2)
printf("scanning library `%s', pass %d...\n", cur->name, pass);
More information about the Nasm-commits
mailing list