Fix valgrind complaints of uninitialized memory

This commit is contained in:
Pasi Kallinen
2016-05-23 16:21:36 +03:00
parent bc91a01fdd
commit e37da61b30
6 changed files with 7 additions and 1 deletions

View File

@@ -337,6 +337,7 @@ int x, y, typ;
} else {
oldplace = FALSE;
ttmp = newtrap();
(void) memset((genericptr_t)ttmp, 0, sizeof(struct trap));
ttmp->ntrap = 0;
ttmp->tx = x;
ttmp->ty = y;