diff options
| author | Mikhail Osipov <mike.osipov@gmail.com> | 2013-11-05 22:46:55 +0400 |
|---|---|---|
| committer | Mikhail Osipov <mike.osipov@gmail.com> | 2013-11-05 22:49:21 +0400 |
| commit | 9562ccd81e1e77e41e9fc66fc367bd46baf3ff6b (patch) | |
| tree | 0815de160fc37daf4165bb04c74b0db4f7d1a993 | |
| parent | 2bb39647a32c51e981070e08c5d3c4a5c2e631e4 (diff) | |
sigint handler
| -rwxr-xr-x | cutter.py | 7 | ||||
| -rw-r--r-- | cutter/formats/sox.py | 2 |
2 files changed, 8 insertions, 1 deletions
@@ -7,6 +7,7 @@ from cutter.tools import * from optparse import OptionParser, OptionGroup +import signal import sys import os import re @@ -251,7 +252,13 @@ def find_cuefile(path): def switch(value, opts): opts.get(value, lambda: None)() +def sigint_handler(sig, frame): + printf("\n") + sys.exit(1) + def main(): + signal.signal(signal.SIGINT, sigint_handler) + options, args = parse_args() if not process_options(options): sys.exit(1) diff --git a/cutter/formats/sox.py b/cutter/formats/sox.py index 2a28a24..eea6583 100644 --- a/cutter/formats/sox.py +++ b/cutter/formats/sox.py @@ -6,7 +6,7 @@ class SoxHandler: self.compression = value def sox_args(self, path, opt, info): - args = ["sox", "-V2", "-"] + args = ["sox", "-V1", "-"] if self.compression is not None: args.extend(["-C", str(self.compression)]) |
