From 569510fbdc245f6b68fdb8c80aae3f2b985e4f2c Mon Sep 17 00:00:00 2001 From: Henri Sivonen Date: Tue, 28 Aug 2018 14:50:11 +0000 Subject: [PATCH] Bug 1485289 - Use BeginWriting() instead of GetMutableData() in LateWriteChecks. r=froydnj MozReview-Commit-ID: G64L8b6wnO0 Differential Revision: https://phabricator.services.mozilla.com/D3963 --HG-- extra : moz-landing-system : lando --- xpcom/build/LateWriteChecks.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/xpcom/build/LateWriteChecks.cpp b/xpcom/build/LateWriteChecks.cpp index 8ef30a567093..1dbe7110fe39 100644 --- a/xpcom/build/LateWriteChecks.cpp +++ b/xpcom/build/LateWriteChecks.cpp @@ -133,8 +133,7 @@ LateWriteObserver::Observe(IOInterposeObserver::Observation& aOb) nsTAutoString nameAux(mProfileDirectory); nameAux.AppendLiteral(NS_SLASH "Telemetry.LateWriteTmpXXXXXX"); - char_type* name; - nameAux.GetMutableData(&name); + char_type* name = nameAux.BeginWriting(); // We want the sha1 of the entire file, so please don't write to fd // directly; use sha1Stream.