Patch for broken pipe errors in LaTeX to PNG code.