Jacek Caban : wininet: Use secure variable instead of ssl_s handle in a few more places.
Alexandre Julliard
julliard at winehq.org
Mon Mar 4 13:23:39 CST 2013
Module: wine
Branch: master
Commit: 125583c4d9e7a0b2610df2e4374729631f57db53
URL: http://source.winehq.org/git/wine.git/?a=commit;h=125583c4d9e7a0b2610df2e4374729631f57db53
Author: Jacek Caban <jacek at codeweavers.com>
Date: Mon Mar 4 17:48:59 2013 +0100
wininet: Use secure variable instead of ssl_s handle in a few more places.
---
dlls/wininet/netconnection.c | 14 +++++++-------
1 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/dlls/wininet/netconnection.c b/dlls/wininet/netconnection.c
index e423830..0d74adf 100644
--- a/dlls/wininet/netconnection.c
+++ b/dlls/wininet/netconnection.c
@@ -702,12 +702,12 @@ void free_netconn(netconn_t *netconn)
{
server_release(netconn->server);
+ if (netconn->secure) {
#ifdef SONAME_LIBSSL
- if (netconn->ssl_s) {
pSSL_shutdown(netconn->ssl_s);
pSSL_free(netconn->ssl_s);
- }
#endif
+ }
closesocket(netconn->socket);
heap_free(netconn);
@@ -936,7 +936,7 @@ DWORD NETCON_send(netconn_t *connection, const void *msg, size_t len, int flags,
else
{
#ifdef SONAME_LIBSSL
- if(!connection->ssl_s) {
+ if(!connection->secure) {
FIXME("not connected\n");
return ERROR_NOT_SUPPORTED;
}
@@ -972,7 +972,7 @@ DWORD NETCON_recv(netconn_t *connection, void *buf, size_t len, int flags, int *
else
{
#ifdef SONAME_LIBSSL
- if(!connection->ssl_s) {
+ if(!connection->secure) {
FIXME("not connected\n");
return ERROR_NOT_SUPPORTED;
}
@@ -1015,7 +1015,7 @@ BOOL NETCON_query_data_available(netconn_t *connection, DWORD *available)
else
{
#ifdef SONAME_LIBSSL
- *available = connection->ssl_s ? pSSL_pending(connection->ssl_s) : 0;
+ *available = pSSL_pending(connection->ssl_s);
#else
FIXME("not supported on this platform\n");
return FALSE;
@@ -1060,7 +1060,7 @@ LPCVOID NETCON_GetCert(netconn_t *connection)
X509* cert;
LPCVOID r = NULL;
- if (!connection->ssl_s)
+ if (!connection->secure)
return NULL;
cert = pSSL_get_peer_certificate(connection->ssl_s);
@@ -1082,7 +1082,7 @@ int NETCON_GetCipherStrength(netconn_t *connection)
#endif
int bits = 0;
- if (!connection->ssl_s)
+ if (!connection->secure)
return 0;
cipher = pSSL_get_current_cipher(connection->ssl_s);
if (!cipher)
More information about the wine-cvs
mailing list