-
- Downloads
upnp: code improvements and bug fixes
This patch adds many improvements and bug fixes: 1- For PUPNP lib, use the synchronous methods for add and remove requests. The async versions have many issues mainly at shutdown. If the callbacks do not arrive on time, the memory allocated by the lib when performing the request will leak. 2- Rework the init and IGD search of PUPNP. 3- Move the termination step (for libupnp in particular) from the destructor to a newly added method (termiinate()). This will prevent a race at shutdown between libupnp threads (callbacks) and the daemon shutdown process. 4- Do not try to initialize libupnp if the host address is invalid. This will prevent putting the lib in an unstable state. Gitlab: #472 Change-Id: I14e5ddcd2b735da374a1f09bcef40f6a86a38133
Showing
- src/manager.cpp 6 additions, 1 deletionsrc/manager.cpp
- src/upnp/protocol/natpmp/nat_pmp.cpp 35 additions, 7 deletionssrc/upnp/protocol/natpmp/nat_pmp.cpp
- src/upnp/protocol/natpmp/nat_pmp.h 4 additions, 0 deletionssrc/upnp/protocol/natpmp/nat_pmp.h
- src/upnp/protocol/pupnp/pupnp.cpp 454 additions, 286 deletionssrc/upnp/protocol/pupnp/pupnp.cpp
- src/upnp/protocol/pupnp/pupnp.h 31 additions, 28 deletionssrc/upnp/protocol/pupnp/pupnp.h
- src/upnp/protocol/upnp_protocol.h 4 additions, 1 deletionsrc/upnp/protocol/upnp_protocol.h
- src/upnp/upnp_context.cpp 33 additions, 28 deletionssrc/upnp/upnp_context.cpp
- src/upnp/upnp_context.h 4 additions, 1 deletionsrc/upnp/upnp_context.h
Loading
Please register or sign in to comment