Bug 1422856 - Stop using GetNativePath in GMPServiceParent. r?cpearce draft
authorMasatoshi Kimura <VYV03354@nifty.ne.jp>
Tue, 05 Dec 2017 01:05:36 +0900
changeset 707508 13a1d26d17f355fe984b37f4e2b597657e7b8623
parent 707507 84fdac93a60fdb7a6683e6c9aec776a7c5bef013
child 742956 ade75c803cde66fabe4f2725838b82b6df645106
push id92131
push userVYV03354@nifty.ne.jp
push dateTue, 05 Dec 2017 11:01:22 +0000
reviewerscpearce
bugs1422856
milestone59.0a1
Bug 1422856 - Stop using GetNativePath in GMPServiceParent. r?cpearce MozReview-Commit-ID: 2zr2RfZOPYs
dom/media/gmp/GMPServiceParent.cpp
--- a/dom/media/gmp/GMPServiceParent.cpp
+++ b/dom/media/gmp/GMPServiceParent.cpp
@@ -970,22 +970,20 @@ static void Dummy(RefPtr<GMPParent>& aOn
 }
 
 void
 GeckoMediaPluginServiceParent::PluginTerminated(const RefPtr<GMPParent>& aPlugin)
 {
   MOZ_ASSERT(mGMPThread->EventTarget()->IsOnCurrentThread());
 
   if (aPlugin->IsMarkedForDeletion()) {
-    nsCString path8;
+    nsString path;
     RefPtr<nsIFile> dir = aPlugin->GetDirectory();
-    nsresult rv = dir->GetNativePath(path8);
+    nsresult rv = dir->GetPath(path);
     NS_ENSURE_SUCCESS_VOID(rv);
-
-    nsString path = NS_ConvertUTF8toUTF16(path8);
     if (mPluginsWaitingForDeletion.Contains(path)) {
       RemoveOnGMPThread(path, true /* delete */, true /* can defer */);
     }
   }
 }
 
 void
 GeckoMediaPluginServiceParent::ReAddOnGMPThread(const RefPtr<GMPParent>& aOld)