bit mask fix