Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
9EOR9 committed Mar 2, 2016
2 parents e157d4f + 33ebe89 commit ea0f2e6
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,7 @@ IF(NOT WITH_SSL STREQUAL "OFF")
ADD_DEFINITIONS(-DHAVE_OPENSSL -DHAVE_SSL)
SET(SSL_SOURCES "${CMAKE_SOURCE_DIR}/libmariadb/secure/openssl.c")
SET(SSL_LIBRARIES ${OPENSSL_LIBRARIES} ${OPENSSL_CRYPTO_LIBRARIES})
INCLUDE_DIRECTORIES(BEFORE ${OPENSSL_INCLUDE_DIRS})
MESSAGE(STATUS "OpenSSL version: ${OPENSSL_VERSION}")
ELSE()
MESSAGE(WARNING "OpenSSL not found")
Expand Down
4 changes: 4 additions & 0 deletions libmariadb/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -273,6 +273,10 @@ IF(WIN32)
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/win-iconv)
SET(LIBMARIADB_SOURCES ${LIBMARIADB_SOURCES}
${CMAKE_SOURCE_DIR}/win-iconv/win_iconv.c)
ELSE()
IF(ICONV_INCLUDE_DIR)
INCLUDE_DIRECTORIES(BEFORE ${ICONV_INCLUDE_DIR})
ENDIF()
ENDIF()

IF(ZLIB_FOUND)
Expand Down
3 changes: 2 additions & 1 deletion plugins/pvio/pvio_socket.c
Original file line number Diff line number Diff line change
Expand Up @@ -521,7 +521,8 @@ int pvio_socket_wait_io_or_timeout(MARIADB_PVIO *pvio, my_bool is_read, int time
else if (FD_ISSET(csock->socket, &exc_fds))
{
int err;
if (getsockopt(csock->socket, SOL_SOCKET, SO_ERROR, (char *)&err, sizeof(err)) != SOCKET_ERROR)
int len = sizeof(int);
if (getsockopt(csock->socket, SOL_SOCKET, SO_ERROR, (char *)&err, &len) != SOCKET_ERROR)
{
errno= err;
}
Expand Down

0 comments on commit ea0f2e6

Please sign in to comment.