correct bitmask check