summaryrefslogtreecommitdiffstats
path: root/skia/ext
diff options
context:
space:
mode:
authorbrettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-01-12 20:08:50 +0000
committerbrettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-01-12 20:08:50 +0000
commit2786f3db2489aa1fd2453fa85745e5c5658b1cd1 (patch)
tree905f82e544746d33d6cc4a3f760a345f648a4fd1 /skia/ext
parentb734450b86e9d6bd7a07b381c119ca91803ae46b (diff)
downloadchromium_src-2786f3db2489aa1fd2453fa85745e5c5658b1cd1.zip
chromium_src-2786f3db2489aa1fd2453fa85745e5c5658b1cd1.tar.gz
chromium_src-2786f3db2489aa1fd2453fa85745e5c5658b1cd1.tar.bz2
Hook up skia's assertions to our logging system.
Review URL: http://codereview.chromium.org/17285 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@7889 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'skia/ext')
-rw-r--r--skia/ext/google_logging.cc20
1 files changed, 20 insertions, 0 deletions
diff --git a/skia/ext/google_logging.cc b/skia/ext/google_logging.cc
new file mode 100644
index 0000000..c69d873
--- /dev/null
+++ b/skia/ext/google_logging.cc
@@ -0,0 +1,20 @@
+// Copyright (c) 2009 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// This file provides integration with Google-style "base/logging.h" assertions
+// for Skia SkASSERT. If you don't want this, you can link with another file
+// that provides integration with the logging of your choice.
+
+#include "base/logging.h"
+#include "base/string_util.h"
+
+void SkDebugf_FileLine(const char* file, int line, const char* format, ...) {
+ va_list ap;
+ va_start(ap, format);
+
+ std::string msg;
+ StringAppendV(&msg, format, ap);
+
+ logging::LogMessage(file, line, logging::LOG_ERROR).stream() << msg;
+}