mirror of
https://github.com/restic/restic.git
synced 2025-04-25 03:24:26 +00:00

This code is introduced to watch for issue #529, in which two users describe that restic failed encoding a time in a node to JSON with the error message: panic: json: error calling MarshalJSON for type *restic.Node: json: error calling MarshalJSON for type time.Time: Time.MarshalJSON: year outside of range [0,9999] The error message now is: panic: Marshal: json: error calling MarshalJSON for type *restic.Node: node /home/fd0/shared/work/restic/restic/.git/hooks/applypatch-msg.sample has invalid ModTime year -1: -0001-01-02 03:04:05.000000006 +0053 LMT