Fresh off the press is version 3! I've changed quite a few things under the hood of PTssh and hopefully this will make PTssh much more robust and easier to use. The big change that's likely to effect people the most is the C API has changed. Now all C functions are preceded with "ptssh_" to help avoid function collisions when using PTssh as a .DLL or .SO
Changelog for 0.3.0 alpha
-Updated the C API to prepend all function calls with "ptssh_". This more closely follows most C style libs and should also help keep function naming collisions low. Thanks to Joe M. for pointing this out.
-Fixed a problem where the SocketSend thread would make CPU usage spike every now and then even if there wasn't anything waiting to be sent.
-Fixed a potential threading problem in the SftpRequestMgr class. This could potentially let one thread add or remove a Sftp request while another was looking up a Sftp request and then end up looking at the wrong request because of the first thead adding/removing a sftp request in the list at just the right moment.
-Fixed the restriction on having a maximum number of Sftp requests. You can now make as many sftp requests simultaneously as your system can handle.
-Fixed an issue with shutting down PTssh where the SocketSend and/or SocketRecieve threads would not shutdown properly and could cause a deadlock. The thread shutdown logic was re-written, the original stuff was crappy.
-Fixed an issue with SocketSend and SocketRecieve threads not properly detecting and handling socket disconnection or dropped connections.
-Fixed several build problems due to some missing #defines
-Removed the usage of the Select() function call. PTssh now does not need the select function.
-Added disconnect callback support. PTssh can now let the end-developer register a function callback that gets called if the socket goes down or gets dropped. The developer can also store a pointer such that it will be available when the callback occurs, PTssh holds it as a void* in its CallbackData struct.
-Use of the PTSSH_ENABLE_LOGGING macro is now fully supported: Added the PTLOG macro. Using PTLOG instead of ptLog will let us compile in or out all logging messages. This will help PTssh have a much smaller footprint on embedded systems, or allow developers to completely disable PTssh's debugging messages. If you comment out the PTSSH_ENABLE_LOGGING #define, all of PTssh's debugging messages will not be compiled into the build. Saves about 10K
-Fixed some build issues under VS2k8 with zlib enabled on the Sftp_usingClass and MultipleConnectionManager projects