The function suffers the same problem as reported in #3457592. time2str() in hpi_shell/service.c.
Seems like duplicated code, should be removed :)
Fixed in trunk (rev. #7391)
Fixed in trunk (rev. #7391)