Update src/core/s-trim.c

2013.02.02 by CCX (cc@x.isla.pr)

>> trim "  x ^/"
== "x x^/"

Fixed that trim bug, found in trim_head_tail(). Changed some var
names and the function declaration to make easier to understand
the algorithm. Now head and tail are trimmed first because its
simpler that way.

First time I ever use github...