I create a control point based on UPnP SDK.
I think i found some bug. When i try to get service
description XML greater then 16000 bytes, i receive a
erroro -119(BAD_HTTPMSG).
When i try to change the max content len value, i
receive a INVALID_HANDLE error.
In source codes i found UpnpSetContentLength function
declaration. When estimate it i understand that when is
a device then function change maxcontetnlen, else cases
return error.
i think it's wrong.
Patch attached.
mailto: raydudu[at]gmail.com.remove.me
Logged In: NO
patch:
__CUT_HERE__
diff -ur libupnp-1.2.1/upnp/src/api/upnpapi.c
libupnp-1.2.1_p/upnp/src/api/upnpapi.c
--- libupnp-1.2.1/upnp/src/api/upnpapi.c 2003-01-15
23:39:43.000000000 +0200
+++ libupnp-1.2.1_p/upnp/src/api/upnpapi.c 2006-01-18
16:34:47.000000000 +0200
@@ -4174,8 +4174,7 @@
errCode = GetHandleInfo( Hnd, &HInfo );
- if( errCode != HND_DEVICE ) {
- errCode = UPNP_E_INVALID_HANDLE;
+ if( errCode == UPNP_E_INVALID_HANDLE ) {
break;
}
__CUT_HERE__