Use memset_s for wiping buffers instead of memset