I feel like when i looked at this a number of months ago you should add -inputformat none here.  I can't remember the exact reasoning but I felt like stdin redirection caused hangs or some other bizarre scenario. i worked around it, but figured i'd mention it.