www.libssh2.org | Daily snapshots | Mailing list archive | Docs | Examples | github

Archive Index This month's Index

Subject: Suggested patches for WinCNG

Suggested patches for WinCNG

From: Bob Kast <bob_2824_at_hotmail.com>
Date: Wed, 19 Mar 2014 17:37:19 -0400

Attached are a set of suggested patches.


Brief explanation:



In Windows, a socket is of type SOCKET, not int.



Redundant #define inline

A one bit bit-field should be unsigned



You shouldn’t need Openssl to compile if you aren’t selecting it.



Putting the #pragma for the libraries works for both DLL and LIB versions.

_libssh2_wincng_hash_update: the parameter needs to be const to match. It is interesting that C just gives a warning for that.

pPaddingInfo value is undefined. Doc says it must be NULL if not used.



STATUS_SUCCESS unfortunately not defined if using non-driver includes.

_libssh2_wincng_hash_ctx and _libssh2_wincng_key_ctx: I found this confusing. Kind of a circular #define. I think this is more of what was intended.

Forward declarations: without these the compiler complains for each call.



Pragma to suppress “possible loss of data” warnings.


New Files:

- Libssh2.sln – solution file

- Libssh2.vcxproj, libssh2.vcxproj.filters – project files for libssh2

- Tests.vcxproj, tests.vcxproj.filters – project files for tests – I haven’t tested this.

These are specifically for VS2013 and make it easy to create DLL/LIB, Debug/Release, 32/64 bit builds.




libssh2-devel http://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel

Received on 2014-03-19

the libssh2 team