HM/JPM: suppressing and restoring standard error stream