Commit 44653302 by Jamie Madill Committed by Commit Bot

Use fprintf(stderr) instead of std::cerr.

This allows us to include <ostream> instead of <iostream> to avoid including a static initializer. BUG=angleproject:2037 Change-Id: Ib7e84a15018fa951bad1c87ffec4bfb0c896749f Reviewed-on: https://chromium-review.googlesource.com/507627Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
parent 1a310b84
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
#include <array> #include <array>
#include <cstdio> #include <cstdio>
#include <fstream> #include <fstream>
#include <iostream> #include <ostream>
#include <vector> #include <vector>
#include "common/angleutils.h" #include "common/angleutils.h"
...@@ -162,7 +162,8 @@ void Trace(LogSeverity severity, const char *message) ...@@ -162,7 +162,8 @@ void Trace(LogSeverity severity, const char *message)
if (severity == LOG_ERR) if (severity == LOG_ERR)
{ {
std::cerr << LogSeverityName(severity) << ": " << str << std::endl; // Note: we use fprintf because <iostream> includes static initializers.
fprintf(stderr, "%s: %s\n", LogSeverityName(severity), str.c_str());
} }
#if defined(ANGLE_PLATFORM_WINDOWS) && \ #if defined(ANGLE_PLATFORM_WINDOWS) && \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment