[stunnel-users] Win CE build errors: main_execute() removed from stunnel.c file? "hwnd" link error.

Pierre DELAAGE delaage.pierre at free.fr
Thu Dec 6 21:30:50 CET 2012

Dear Michal,
Well, I always check msdocs directly, from msdn, and I check it on local 
install of vstudio express embedded docs, and on embedded doc from WCE 5 
sdk, and an old msdn 2000 cd I have (I am concerned with compatibility 
with old and new systems).

A least, I can say that the 3 functions are available in winsock2 for 
WCE. (ws2_lib),
and on most of Windows version above or equal to xp.

And when I say winsock2 (ws2 lib) , it is not winsock1 (winsock lib).

For windows 2000 pro, check this :



        Support for getaddrinfo on Windows 2000 and older versions

The *getaddrinfo* function was added to the Ws2_32.dll on Windows XP and 
later. To execute an application that uses this function on earlier 
versions of Windows, then you need to include the /Ws2tcpip.h/ and 
/Wspiapi.h/ files. When the /Wspiapi.h/ include file is added, the 
*getaddrinfo* function is defined to the *WspiapiGetAddrInfo* inline 
function in the /Wspiapi.h/ file. At runtime, the *WspiapiGetAddrInfo* 
function is implemented in such a way that if the Ws2_32.dll or the 
Wship6.dll (the file containing *getaddrinfo* in the IPv6 Technology 
Preview for Windows 2000) does not include *getaddrinfo*, then a version 
of *getaddrinfo* is implemented inline based on code in the Wspiapi.h 
header file. This inline code will be used on older Windows platforms 
that do not natively support the *getaddrinfo* function.

The IPv6 protocol is supported on Windows 2000 when the IPv6 Technology 
Preview for Windows 2000 is installed. Otherwise *getaddrinfo* support 
on versions of Windows earlier than Windows XP is limited to handling 
IPv4 name resolution.

The *GetAddrInfoW* 
function is the Unicode version of *getaddrinfo*. The *GetAddrInfoW* 
function was added to the Ws2_32.dll in Windows XP with Service Pack 2 
(SP2). The *GetAddrInfoW* function cannot be used on versions of Windows 
earlier than Windows XP with SP2.

*Windows Phone 8:* This API is supported.


Minimum supported client

	Windows 2000 Professional [desktop apps only]

Minimum supported server

	Windows 2000 Server [desktop apps only]



Ws2tcpip.h on Windows 2000 (include Wspiapi.h)








My sole purpose was to replace winsock1 lib an h files with those of 
winsock2 (see my modified common.h I sent you in 2010/11),
as winsock2 is available on many windows version, including 2000.

Some strange redef in common.h leading to compilation warnings were 
clarified with the distinction between winsock1 and winsock2.

Well, I think that at least for CE, the code "could" be adapted as I 
offered (because the present code let us think that getaddrinfo is NOT 
available in ws2 lib, and IT IS:
http://msdn.microsoft.com/en-us/library/aa915647.aspx ).

Well, I will wait for v500 official and maybe suggest an adaptation for 
WCE or JUST FOR W2000...

Yours sincerely,

Le 06/12/2012 20:37, Michal Trojnara a écrit :
> On 2012-12-04 13:43, Pierre DELAAGE wrote:
>> In the past, my offer was to simplify the code for "custom" rewrites of
>> getaddrinfo/getnameinfo in resolver.c,
>> by using winsock2 api,
>> because such calls are available in winsock2, and NOT in winsock1.
> You are wrong.  Winsock2 does *not* imply getaddrinfo/getnameinfo.
> The original Windows 2000 does have Winsock2, but it doesn't have
> getaddrinfo/getnameinfo.  Feel free do check it for yourself if you
> don't believe me (or Microsoft docs I sent you).
>> I will check this in depth after official stunnel v5.00.
> Thank you.
> Mike
> _______________________________________________
> stunnel-users mailing list
> stunnel-users at stunnel.org
> https://www.stunnel.org/cgi-bin/mailman/listinfo/stunnel-users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.stunnel.org/pipermail/stunnel-users/attachments/20121206/226ce16d/attachment.html>

More information about the stunnel-users mailing list