fix stdin opening and stdout name in filterTable