Bug 1278452 - Remove an unnecessary null check in js/src/shell/. r=sfink.
authorNicholas Nethercote <nnethercote@mozilla.com>
Tue, 07 Jun 2016 14:33:12 +1000
changeset 301021 9d63042e0d38c658599b0770aa6f821ef8d59ad8
parent 301020 62f467b82836692a97158d2fa5a2896fb11a1d1e
child 301022 4b3df77d399ad1be7c9df0987a0e1f0c9226a2d4
push id19599
push usercbook@mozilla.com
push dateWed, 08 Jun 2016 10:16:21 +0000
treeherderfx-team@81f4cc3f6f4c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssfink
bugs1278452
milestone50.0a1
Bug 1278452 - Remove an unnecessary null check in js/src/shell/. r=sfink.
js/src/shell/js.cpp
--- a/js/src/shell/js.cpp
+++ b/js/src/shell/js.cpp
@@ -1961,17 +1961,17 @@ ValueToScript(JSContext* cx, Value vArg,
         JS_ReportErrorNumber(cx, my_GetErrorMessage, nullptr, JSSMSG_SCRIPTS_ONLY);
         return nullptr;
     }
 
     JSScript* script = fun->getOrCreateScript(cx);
     if (!script)
         return nullptr;
 
-    if (fun && funp)
+    if (funp)
         *funp = fun;
 
     return script;
 }
 
 static JSScript*
 GetTopScript(JSContext* cx)
 {