Hi Khaled,

I don't know if I can help you with that, I have never seen libupnp take so much memory per task, but I must confess I have not been using it for quite a long time, now I am just helping maintaing the library.

I would suggest you to debug your problem using valgrind. It is very good at catching memory leaks, worth a try.

Oh, and when you find the bug, please send us the patch :)

Best regards,
Marcelo.