Print errors to cerr instead of cout.