[vlc-devel] [PATCH 1/4] Fix check for plugin table size
Cheng Sun
chengsun9 at gmail.com
Sun Dec 30 21:51:52 CET 2012
---
npapi/support/npunix.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/npapi/support/npunix.cpp b/npapi/support/npunix.cpp
index 0f4baaf..1f3f778 100644
--- a/npapi/support/npunix.cpp
+++ b/npapi/support/npunix.cpp
@@ -847,7 +847,7 @@ NP_Initialize(NPNetscapeFuncs* nsTable, NPPluginFuncs* pluginFuncs)
err = NPERR_INCOMPATIBLE_VERSION_ERROR;
if (nsTable->size < ((char *)&nsTable->posturlnotify - (char *)nsTable))
err = NPERR_INVALID_FUNCTABLE_ERROR;
- if (pluginFuncs->size < sizeof(NPPluginFuncs))
+ if (pluginFuncs->size < (char *)&pluginFuncs->setvalue - (char *)pluginFuncs)
err = NPERR_INVALID_FUNCTABLE_ERROR;
}
--
1.8.0.3
More information about the vlc-devel
mailing list