Fix boolean checks in isFFmpegCommandRunning and killRunningProcesses