native c bug fix