diff options
author | wolfbeast <mcwerewolf@gmail.com> | 2018-09-04 10:06:24 +0200 |
---|---|---|
committer | wolfbeast <mcwerewolf@gmail.com> | 2018-09-04 10:07:40 +0200 |
commit | b28ab55f9675f2e97dda9a4fcac0d4f5267a2bb9 (patch) | |
tree | 0b6e4cfff6c1d4f699aa04c98c27744b4c0c481f /dom/plugins/ipc/PluginModuleParent.cpp | |
parent | 45ec2bceb4822646805136b8874a3681b14e78ef (diff) | |
parent | 93cae908bcbd063f21d5663a7d3149464af2ad20 (diff) | |
download | UXP-b28ab55f9675f2e97dda9a4fcac0d4f5267a2bb9.tar UXP-b28ab55f9675f2e97dda9a4fcac0d4f5267a2bb9.tar.gz UXP-b28ab55f9675f2e97dda9a4fcac0d4f5267a2bb9.tar.lz UXP-b28ab55f9675f2e97dda9a4fcac0d4f5267a2bb9.tar.xz UXP-b28ab55f9675f2e97dda9a4fcac0d4f5267a2bb9.zip |
Remove all C++ telemetry autotimers
Tag #21
Diffstat (limited to 'dom/plugins/ipc/PluginModuleParent.cpp')
-rwxr-xr-x | dom/plugins/ipc/PluginModuleParent.cpp | 34 |
1 files changed, 15 insertions, 19 deletions
diff --git a/dom/plugins/ipc/PluginModuleParent.cpp b/dom/plugins/ipc/PluginModuleParent.cpp index f04cd209c..300c4f621 100755 --- a/dom/plugins/ipc/PluginModuleParent.cpp +++ b/dom/plugins/ipc/PluginModuleParent.cpp @@ -2284,27 +2284,23 @@ PluginModuleParent::NPP_NewInternal(NPMIMEType pluginType, NPP instance, return NS_ERROR_FAILURE; } - { // Scope for timer - Telemetry::AutoTimer<Telemetry::BLOCKED_ON_PLUGIN_INSTANCE_INIT_MS> - timer(GetHistogramKey()); - if (mIsStartingAsync) { - MOZ_ASSERT(surrogate); - surrogate->AsyncCallDeparting(); - if (!SendAsyncNPP_New(parentInstance)) { + if (mIsStartingAsync) { + MOZ_ASSERT(surrogate); + surrogate->AsyncCallDeparting(); + if (!SendAsyncNPP_New(parentInstance)) { + *error = NPERR_GENERIC_ERROR; + return NS_ERROR_FAILURE; + } + *error = NPERR_NO_ERROR; + } else { + if (!CallSyncNPP_New(parentInstance, error)) { + // if IPC is down, we'll get an immediate "failed" return, but + // without *error being set. So make sure that the error + // condition is signaled to nsNPAPIPluginInstance + if (NPERR_NO_ERROR == *error) { *error = NPERR_GENERIC_ERROR; - return NS_ERROR_FAILURE; - } - *error = NPERR_NO_ERROR; - } else { - if (!CallSyncNPP_New(parentInstance, error)) { - // if IPC is down, we'll get an immediate "failed" return, but - // without *error being set. So make sure that the error - // condition is signaled to nsNPAPIPluginInstance - if (NPERR_NO_ERROR == *error) { - *error = NPERR_GENERIC_ERROR; - } - return NS_ERROR_FAILURE; } + return NS_ERROR_FAILURE; } } |