Bug 944844 - Disambiguate the printf functions in GeckoProfilerImpl.h so that they don't conflict with the ones defined in chromium's namespace base; r=BenWa
authorEhsan Akhgari <ehsan@mozilla.com>
Mon, 02 Dec 2013 12:29:49 -0500
changeset 158289 46680cc56bcfb94d2b89d143c29992dc79eaf12a
parent 158288 90fb9ca640e43eb3983c5bb99083d95bfd764637
child 158290 66be4716e86e33ebc37d324313b622d9193498a5
push id36957
push usereakhgari@mozilla.com
push dateMon, 02 Dec 2013 17:29:57 +0000
treeherdermozilla-inbound@46680cc56bcf [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersBenWa
bugs944844
milestone28.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 944844 - Disambiguate the printf functions in GeckoProfilerImpl.h so that they don't conflict with the ones defined in chromium's namespace base; r=BenWa
tools/profiler/GeckoProfilerImpl.h
--- a/tools/profiler/GeckoProfilerImpl.h
+++ b/tools/profiler/GeckoProfilerImpl.h
@@ -301,18 +301,18 @@ public:
       char buff[SAMPLER_MAX_STRING];
 
       // We have to use seperate printf's because we're using
       // the vargs.
 #if _MSC_VER
       _vsnprintf(buff, SAMPLER_MAX_STRING, aFormat, args);
       _snprintf(mDest, SAMPLER_MAX_STRING, "%s %s", aDefault, buff);
 #else
-      vsnprintf(buff, SAMPLER_MAX_STRING, aFormat, args);
-      snprintf(mDest, SAMPLER_MAX_STRING, "%s %s", aDefault, buff);
+      ::vsnprintf(buff, SAMPLER_MAX_STRING, aFormat, args);
+      ::snprintf(mDest, SAMPLER_MAX_STRING, "%s %s", aDefault, buff);
 #endif
       mHandle = mozilla_sampler_call_enter(mDest, this, true, line);
       va_end(args);
     } else {
       mHandle = mozilla_sampler_call_enter(aDefault, nullptr, false, line);
     }
   }
   ~SamplerStackFramePrintfRAII() {