summaryrefslogtreecommitdiffstats
path: root/base/debug_util_posix.cc
diff options
context:
space:
mode:
authorcraig.schlenter@chromium.org <craig.schlenter@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-09-18 15:27:56 +0000
committercraig.schlenter@chromium.org <craig.schlenter@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-09-18 15:27:56 +0000
commitf358a0aaf43f8356a331373132ed4527772d65b5 (patch)
tree07b64b497fe9e2c2440e97ced217de1cde9e168b /base/debug_util_posix.cc
parentd8a5be2c65c3038cd6073d58458cd78815130391 (diff)
downloadchromium_src-f358a0aaf43f8356a331373132ed4527772d65b5.zip
chromium_src-f358a0aaf43f8356a331373132ed4527772d65b5.tar.gz
chromium_src-f358a0aaf43f8356a331373132ed4527772d65b5.tar.bz2
Explicitly compare to NULL when looking for weak_import symbols.
Changing the comparison form affects the warning messages generated in various circumstances. See the codereview for details. Also, Apple docs claim that !symbol comparisons will not work. Spotted by Matthew Vosburgh. Review URL: http://codereview.chromium.org/214012 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@26569 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/debug_util_posix.cc')
-rw-r--r--base/debug_util_posix.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/base/debug_util_posix.cc b/base/debug_util_posix.cc
index fe72c3c..dc86c8c 100644
--- a/base/debug_util_posix.cc
+++ b/base/debug_util_posix.cc
@@ -121,7 +121,7 @@ void DebugUtil::BreakDebugger() {
StackTrace::StackTrace() {
#if defined(OS_MACOSX) && MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_5
- if (!backtrace) {
+ if (backtrace == NULL) {
count_ = 0;
return;
}
@@ -133,7 +133,7 @@ StackTrace::StackTrace() {
void StackTrace::PrintBacktrace() {
#if defined(OS_MACOSX) && MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_5
- if (!backtrace_symbols_fd)
+ if (backtrace_symbols_fd == NULL)
return;
#endif
fflush(stderr);
@@ -142,7 +142,7 @@ void StackTrace::PrintBacktrace() {
void StackTrace::OutputToStream(std::ostream* os) {
#if defined(OS_MACOSX) && MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_5
- if (!backtrace_symbols)
+ if (backtrace_symbols == NULL)
return;
#endif
scoped_ptr_malloc<char*> trace_symbols(backtrace_symbols(trace_, count_));