matroskaenc: do not write negative timestamps

Bug-Id: 597, 341
sgidec: fix an incorrect backport