fix bug in time diff on unix

When comparing times if the second changes, that change should be taken into account calculating the change in nanoseconds.  If not you can end up with negative differences when the second field increments.