projects
/
srt2vtt.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
708435a
)
subrip: Convert time components from strings to numbers.
author
David Thompson
<dthompson2@worcester.edu>
Sun, 15 Feb 2015 18:50:57 +0000
(13:50 -0500)
committer
David Thompson
<dthompson2@worcester.edu>
Sun, 15 Feb 2015 19:33:38 +0000
(14:33 -0500)
* srt2vtt/subrip.scm (parse-time): Convert matched components to numbers.
srt2vtt/subrip.scm
patch
|
blob
|
history
diff --git
a/srt2vtt/subrip.scm
b/srt2vtt/subrip.scm
index 44f118e8752223e614ad35d437f6203aaea729fc..dd3b53f6500f44efccb1046292c7831cb33379ec 100644
(file)
--- a/
srt2vtt/subrip.scm
+++ b/
srt2vtt/subrip.scm
@@
-32,7
+32,8
@@
element list. Valid input looks like '00:00:03.417'."
(let ((match (regexp-exec regexp s)))
(if match
- (map (cut match:substring match <>) '(1 2 3 4))
+ (map (compose string->number (cut match:substring match <>))
+ '(1 2 3 4))
(error "Invalid SubRip timestamp: " s))))))
(define parse-time-span