Remove memset duplicate calls