int RDPEXT_CC FreeRDPExtensionEntry(PFREERDP_EXTENSION_ENTRY_POINTS pEntryPoints) { xpuPlugin * xpu; xpu = (xpuPlugin *) malloc(sizeof(xpuPlugin)); memset(xpu, 0, sizeof(xpuPlugin)); xpu->plugin.ext = pEntryPoints->ext; xpu->plugin.init = xpu_init; xpu->plugin.uninit = xpu_uninit; if (pEntryPoints->data) { xpu->port = atoi(pEntryPoints->data); } else { xpu->port = 3390; /* default XPU port */ } pEntryPoints->pRegisterExtension((rdpExtPlugin *) xpu); pEntryPoints->pRegisterPreConnectHook((rdpExtPlugin *) xpu, xpu_pre_connect); pEntryPoints->pRegisterPostConnectHook((rdpExtPlugin *) xpu, xpu_post_connect); return 0; }
int RDPEXT_CC FreeRDPExtensionEntry(PFREERDP_EXTENSION_ENTRY_POINTS pEntryPoints) { extTestPlugin * exttest; exttest = (extTestPlugin *) malloc(sizeof(extTestPlugin)); memset(exttest, 0, sizeof(extTestPlugin)); exttest->plugin.ext = pEntryPoints->ext; exttest->plugin.init = exttest_init; exttest->plugin.uninit = exttest_uninit; if (pEntryPoints->data) { exttest->ext_test_data = atoi(pEntryPoints->data); } else { exttest->ext_test_data = -1; } pEntryPoints->pRegisterExtension((rdpExtPlugin *) exttest); pEntryPoints->pRegisterPreConnectHook((rdpExtPlugin *) exttest, exttest_pre_connect); pEntryPoints->pRegisterPostConnectHook((rdpExtPlugin *) exttest, exttest_post_connect); return 0; }