Skip to content
Browse files

And again quoting.

  • Loading branch information...
1 parent 9808aec commit b49eb5ca15e5769f3065f9f39ef36c52aba2e15f @stassats committed Aug 18, 2009
Showing with 4 additions and 3 deletions.
  1. +4 −3 togg
View
7 togg
@@ -36,13 +36,13 @@
(tag output-dir))
(define (quote-for-shell string)
- (regexp-replace* "'" string "\\'"))
+ (regexp-replace* "'" (path->string string) "'\\\\''"))
(define (paths-to-string lis)
(let ((str ""))
(for-each (lambda (x)
(set! str (string-append str " '"
- (quote-for-shell (path->string x))
+ (quote-for-shell x)
"'")))
lis)
str))
@@ -56,7 +56,8 @@
(set! cue '("/tmp/1.cue")))
(system (format "shntool ~a -q -o 'cust ext=ogg ~a/%f' ~a"
(if (and (= (length files) 1) (pair? cue))
- (format "split -t %n_%t -f '~a'" (car cue))
+ (format "split -t %n_%t -f '~a'"
+ (quote-for-shell (car cue)))
"conv")
(encode-command output-dir)
(paths-to-string files)))

0 comments on commit b49eb5c

Please sign in to comment.
Something went wrong with that request. Please try again.