From e050825d32f56bcc6f1b785b8af003434f00bd40 Mon Sep 17 00:00:00 2001 From: waterson Date: Wed, 17 Jun 1998 21:15:23 +0000 Subject: [PATCH] Bug 127280. Approved by don. Make sure reference count is properly initialized in NP_LoadPluginByType(). git-svn-id: svn://10.0.0.236/trunk@4010 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/lib/plugin/npglue.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/mozilla/lib/plugin/npglue.cpp b/mozilla/lib/plugin/npglue.cpp index 252701dc751..09fcdc58146 100644 --- a/mozilla/lib/plugin/npglue.cpp +++ b/mozilla/lib/plugin/npglue.cpp @@ -4204,6 +4204,11 @@ NPL_LoadPluginByType(const char* typeAttribute) return NULL; } loaded = PR_TRUE; + + // Give the handle a ref so we know not to load it again. + // XXX How do we ever _unload_ it once this routine + // has been called??? + handle->refs = 1; #ifdef JAVA /* ** Don't use npn_getJavaEnv here. We don't want to start the