Removing an unnecessary video write
authorChristopher Allan Webber <cwebber@dustycloud.org>
Mon, 4 Mar 2013 17:53:04 +0000 (11:53 -0600)
committerChristopher Allan Webber <cwebber@dustycloud.org>
Mon, 4 Mar 2013 17:53:04 +0000 (11:53 -0600)
In the case of if we're skipping transcoding, we don't need to copy
this file at all!

This commit sponsored by Frank Zambrini III.  Thanks!

mediagoblin/media_types/video/processing.py

index 3da19a08ee079e80f0b5ccae303b7e9999a65105..d6439b7827c49c67bf0b1a26e02e31cfe5cd7a45 100644 (file)
@@ -25,7 +25,6 @@ from mediagoblin.tools.translate import lazy_pass_to_ugettext as _
 from . import transcoders
 from .util import skip_transcode
 
-
 _log = logging.getLogger(__name__)
 _log.setLevel(logging.DEBUG)
 
@@ -94,8 +93,6 @@ def process_video(proc_state):
         # if we can skip it
         if skip_transcode(metadata):
             _log.debug('Skipping transcoding')
-            # Just push the submitted file to the tmp_dst
-            open(tmp_dst.name, 'wb').write(open(queued_filename, 'rb').read())
 
             dst_dimensions = metadata['videowidth'], metadata['videoheight']