lightd: replace strcmp with switch