Update string_state.c

Pattern matching was a little bit more complex than first thought.