diff options
| author | Martin Joerg <martin.joerg@gmail.com> | 2025-05-14 21:44:20 +0000 |
|---|---|---|
| committer | Jonas Bernoulli <jonas@bernoul.li> | 2025-05-15 15:45:03 +0200 |
| commit | 716b9e64374cdd9b0551c4befd3691d8daee4b20 (patch) | |
| tree | c7634f8b15b5b0605077dae46a7c901a94bdbcc5 /lisp/magit-refs.el | |
| parent | 04ee83d93fabbfbe202e9e7dc781b0dcd4d5b502 (diff) | |
magit-refs--format-margin: Do not assume fixes length of timestamps
UNIX timestamps do not have a fixed length.
Co-authored-by: Jonas Bernoulli <jonas@bernoul.li>
Diffstat (limited to 'lisp/magit-refs.el')
| -rw-r--r-- | lisp/magit-refs.el | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lisp/magit-refs.el b/lisp/magit-refs.el index 024acdc..62a8fc5 100644 --- a/lisp/magit-refs.el +++ b/lisp/magit-refs.el @@ -807,10 +807,8 @@ line is inserted at all." (defun magit-refs--format-margin (commit) (save-excursion (goto-char (line-beginning-position 0)) - (let ((line (magit-rev-format "%ct%cN" commit))) - (magit-log-format-margin commit - (substring line 10) - (substring line 0 10))))) + (let ((line (magit-rev-format "%cN%x00%ct" commit))) + (apply #'magit-log-format-margin commit (split-string line "\0"))))) ;;; _ (provide 'magit-refs) |
