Use correct number of seconds between 1900-01-01 and the epoch
This commit is contained in:
parent
6f856c61b6
commit
a710238694
|
@ -209,12 +209,14 @@ If not given, FORMAT-STRING defaults to some ISO 8601-like format."
|
|||
(string-to-number (read-string "Log (hex): ") 16)))
|
||||
(let* ((high-seconds (- high 2208992400)) ; subtract seconds between 1900-01-01 and the epoch
|
||||
(h (lsh high-seconds -16))
|
||||
(let* ((high-seconds (- high 2208988800)) ; subtract seconds between 1900-01-01 and the epoch
|
||||
(l (% high-seconds 65536))
|
||||
(u (floor (* (/ low 4294967296.0) 1e6)))
|
||||
(p (- low (floor (/ (* u 4294967296) 1e6)))))
|
||||
(message
|
||||
(format-time-string (or format-string "%Y-%m-%dT%H:%M:%S.%9NZ")
|
||||
(list h l u p)))))
|
||||
(format-time-string (or format-string "%FT%H:%M:%S.%9NZ")
|
||||
(list h l u p)
|
||||
t))))
|
||||
|
||||
(defun conditionally-enable-lispy ()
|
||||
"Enable lispy-mode when in `eval-expression’ or in
|
||||
|
|
Loading…
Reference in New Issue