fix undefined behavior in fmt_trim()
[mmh] / DATE
1 2016-08-15