Get rid of the sole strtok call in the tree.

It might have (not here, though) side effects, since it isn't reentrant.
Considering that it always has to span five characters (color), use
strspn to simplify the code and save a few lines.