Fix wrong casting in strncmp