From: Urban Wallasch Date: Sun, 9 May 2021 17:01:26 +0000 (+0200) Subject: * Redirect stdout and stderr of player child process to DEVNULL. X-Git-Tag: v0.3~101 X-Git-Url: https://git.packet-gain.de/?a=commitdiff_plain;h=627981868176084e31fa675fd7be251e8ee84574;p=ffpreview.git * Redirect stdout and stderr of player child process to DEVNULL. --- diff --git a/ffpreview.py b/ffpreview.py index 9b30d70..2228eba 100755 --- a/ffpreview.py +++ b/ffpreview.py @@ -53,7 +53,7 @@ import tempfile import argparse import json from configparser import RawConfigParser as ConfigParser -from subprocess import PIPE, Popen +from subprocess import PIPE, Popen, DEVNULL import base64 from PyQt5.QtCore import * from PyQt5.QtWidgets import * @@ -626,7 +626,7 @@ def play_video(filename, start='0', paused=False): cmd = cmd.replace('%t', '"' + start + '"') cmd = cmd.replace('%f', '"' + filename + '"') eprint(cmd) - Popen('exec ' + cmd, shell=True, start_new_session=True) + Popen('exec ' + cmd, shell=True, stdout=DEVNULL, stderr=DEVNULL, start_new_session=True) # check validity of existing index file def chk_idxfile():