diff options
author | lloyd <[email protected]> | 2011-04-29 16:59:29 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2011-04-29 16:59:29 +0000 |
commit | 93b5927837b75d9660084e83adf04c77a57fe4b3 (patch) | |
tree | e3946d10e67182cb5901a217ef1ccc90048b025e /doc/examples/tls_server.cpp | |
parent | 96043ac4c4fdd4e7c23143097922843552b4aa9a (diff) |
Calling &str[str.size()] is only valid if str is const; otherwise the
results are undefined. This happens to work under GCC and most other
compilers, but does not under Visual C++ 2010. This broke hex_encode
when encoding an empty input, and this subsequently broke SSL
handshaking.
2010 includes a TR1 that works fine for SSL, but it puts the headers
in the main header space rather than under tr1/, so account for that.
Hack the socket header into working under WinSock
Tick version to 1.10.0
Diffstat (limited to 'doc/examples/tls_server.cpp')
-rw-r--r-- | doc/examples/tls_server.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/doc/examples/tls_server.cpp b/doc/examples/tls_server.cpp index be5677c12..0c68ead3d 100644 --- a/doc/examples/tls_server.cpp +++ b/doc/examples/tls_server.cpp @@ -39,7 +39,8 @@ int main(int argc, char* argv[]) try { - LibraryInitializer init; + LibraryInitializer botan_init; + SocketInitializer socket_init; AutoSeeded_RNG rng; |