midiogre: check if fopen fails