1
0
mirror of https://github.com/vikstrous/pirate-get synced 2025-01-10 10:04:21 +01:00

Use builtin /dev/null pipe

This commit is contained in:
Rnhmjoj 2015-03-24 23:45:02 +01:00
parent d799d4b5e7
commit ed0649d659

View File

@ -427,8 +427,9 @@ def main():
args = parser.parse_args()
if args.transmission:
with open('/dev/null') as dn:
ret = subprocess.call(['transmission-remote', '-l'], stdout=dn, stderr=dn)
ret = subprocess.call(['transmission-remote', '-l'],
stdout=subprocess.DEVNULL,
stderr=subprocess.DEVNULL)
if ret != 0:
print('Transmission is not running.')
return