el/dot-emacs.el: Use `string-to-number' instead of `parse-integer'.
authorMark Wooding <mdw@distorted.org.uk>
Mon, 17 Jul 2017 12:43:53 +0000 (13:43 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Mon, 17 Jul 2017 12:43:53 +0000 (13:43 +0100)
Not sure where the latter came from (except that it's the Common Lisp
function for doing this job), but it doesn't work on a freshly started
instance.

el/dot-emacs.el

index be261ec..09b3960 100644 (file)
@@ -3784,13 +3784,13 @@ there is sadness."
                  (duration-string (cdr (assq 'Time mpc-status)))
                  (time-string (cdr (assq 'time mpc-status)))
                  (time (and time-string
-                            (parse-integer
+                            (string-to-number
                              (if (string-match ":" time-string)
                                  (substring time-string
                                             0 (match-beginning 0))
                                (time-string)))))
                  (duration (and duration-string
-                                (parse-integer duration-string)))
+                                (string-to-number duration-string)))
                  (pos (and time duration
                            (format " [%d:%02d/%d:%02d]"
                                    (/ time 60) (mod time 60)