fix incorrect memset call