add: if (!iface->tm) {  NS_RELEASE (iface); return FALSE; } NS_RELEASE (iface);
context:  totem_plugin_fork (TotemPlugin *plugin){	GTimeVal then, now;	char *svcname;	char **argv;	int argc = 0;	GError *err = NULL;	argv = (char **)g_new0 (char *, MAX_ARGV_LEN);	if (g_file_test ("./totem-mozilla-viewer",				G_FILE_TEST_EXISTS) != FALSE) {		argv[argc++] = g_strdup ("./totem-mozilla-viewer");	} else {		argv[argc++] = g_strdup (LIBEXECDIR"/totem-mozilla-viewer");	}	argv[argc++] = g_strdup (TOTEM_OPTION_XID);	argv[argc++] = g_strdup_printf ("%lu", plugin->window);	if (plugin->width) {		argv[argc++] = g_strdup (TOTEM_OPTION_WIDTH);		argv[argc++] = g_strdup_printf ("%d", plugin->width);	}	if (plugin->height) {		argv[argc++] = g_strdup (TOTEM_OPTION_HEIGHT);		argv[argc++] = g_strdup_printf ("%d", plugin->height);	}	if (plugin->src) {		argv[argc++] = g_strdup (TOTEM_OPTION_URL);		argv[argc++] = g_strdup (plugin->src);	}		if (plugin->href) {		argv[argc++] = g_strdup (TOTEM_OPTION_HREF);		argv[argc++] = g_strdup (plugin->href);	}	if (plugin->controller_hidden) {		argv[argc++] = g_strdup ("--nocontrols");	}	argv[argc++] = g_strdup ("fd://0");	argv[argc] = NULL;	{		int i;		g_print ("Launching: ");		for (i = 0; i < argc; i++) {			g_print ("%s ", argv[i]);		}		g_print ("\n");	}	if (g_spawn_async_with_pipes (NULL, argv, NULL,				G_SPAWN_DO_NOT_REAP_CHILD,				NULL, NULL, &plugin->player_pid,				&plugin->send_fd, NULL, NULL, &err) == FALSE)	{		DEBUG("Spawn failed");		if (err)		{			fprintf(stderr, "%s\n", err->message);			g_error_free(err);		}		g_strfreev (argv);		return FALSE;	}	g_strfreev (argv);	/* now wait until startup is complete */	plugin->got_svc = FALSE;	plugin->wait_for_svc =		g_strdup_printf ("org.totem_%d.MozillaPluginService",				 plugin->player_pid);	g_print ("waiting for signal %s\n", plugin->wait_for_svc);	dbus_g_proxy_add_signal (plugin->proxy, "NameOwnerChanged",				 G_TYPE_STRING, G_TYPE_STRING,				 G_TYPE_STRING, G_TYPE_INVALID);	dbus_g_proxy_connect_signal (plugin->proxy, "NameOwnerChanged",				     G_CALLBACK (cb_update_name),				     plugin, NULL);	g_get_current_time (&then);	do {		g_main_context_iteration (NULL, TRUE);		g_get_current_time (&now);	} while (!plugin->got_svc &&		 ((guint64) now.tv_sec * 1000000 + now.tv_usec <=		  (guint64) (then.tv_sec + 5) * 1000000 + then.tv_usec));	dbus_g_proxy_disconnect_signal (plugin->proxy, "NameOwnerChanged",					G_CALLBACK (cb_update_name), plugin);	if (!plugin->got_svc) {		fprintf (stderr, "Failed to receive DBUS interface response\n");		g_free (plugin->wait_for_svc);		if (plugin->player_pid) {			kill (plugin->player_pid, SIGKILL);			waitpid (plugin->player_pid, NULL, 0);			plugin->player_pid = 0;		}		return FALSE;	}	g_object_unref (plugin->proxy);	/* now get the proxy for the player functions */	plugin->proxy =		dbus_g_proxy_new_for_name (plugin->conn, plugin->wait_for_svc,					   "/TotemEmbedded",					   "org.totem.MozillaPluginInterface");	g_free (plugin->wait_for_svc);	g_print ("Done forking, new proxy=%p\n", plugin->proxy);	return TRUE;}