Add escaping of $ characters in arguments

Needed if a filename contains $. Could be added to later but for now
hardcoded.
This commit is contained in:
Joshua M. Boniface 2023-05-22 20:27:10 -04:00
parent 4f41b334ef
commit 3a3a3ae738

View file

@ -477,6 +477,8 @@ def run_remote_ffmpeg(
# Append all the passed arguments with requoting of any problematic characters
for arg in ffmpeg_args:
# Escape $ characters
arg = arg.replace('$', '\\$')
# Match bad shell characters: * ' ( ) | [ ] or whitespace
if search("[*'()|\[\]\s]", arg):
rffmpeg_ffmpeg_command.append(f'"{arg}"')