clean code; fix segment operator comparison;