void *Cookie = NULL;
UpnpDevice_Handle DeviceHandle = -1;
char desc_doc_url[MAX_BUF_LEN] = {0};
snprintf(desc_doc_url, MAX_BUF_LEN, "http://%s:%d/%s", IP, PORT, "tvdevicedesc.xml");
iRet = UpnpRegisterRootDevice(desc_doc_url, TvDeviceCallbackEventHandler, Cookie, &DeviceHandle);
if(iRet != UPNP_E_SUCCESS)
{
printf("Error register root device %d\n", iRet);
UpnpFinish();
return iRet;
}
我也不清楚是我的参数传的有问题,还是有什么没初始化,一直返回-104,请各位大神指点