Commit 745dbe97 authored by JP Dinger's avatar JP Dinger

mozilla plugin: cosmetics.

parent 8114a97f
......@@ -799,27 +799,20 @@ LibvlcPlaylistNPObject::invoke(int index, const NPVariant *args,
{
if( (argCount < 1) || (argCount > 3) )
return INVOKERESULT_NO_SUCH_METHOD;
char *url = NULL;
if( !NPVARIANT_IS_STRING(args[0]) )
return INVOKERESULT_NO_SUCH_METHOD;
// grab URL
if( NPVARIANT_IS_STRING(args[0]) )
{
char *s = stringValue(NPVARIANT_TO_STRING(args[0]));
if( s )
{
url = p_plugin->getAbsoluteURL(s);
if( !s )
return INVOKERESULT_OUT_OF_MEMORY;
char *url = p_plugin->getAbsoluteURL(s);
if( url )
free(s);
else
// problem with combining url, use argument
url = s;
}
else
return INVOKERESULT_OUT_OF_MEMORY;
}
else
return INVOKERESULT_NO_SUCH_METHOD;
char *name = NULL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment