Commit 001c44b9 authored by EVPath Upstream's avatar EVPath Upstream Committed by Eisenhauer, Greg
Browse files

EVPath 2018-06-14 (0e42b8db)

Code extracted from:

    https://github.com/GTkorvo/EVPath.git

at commit 0e42b8db5e0c00d4f9b6bbdd7342042cc1886a34 (master).

Upstream Shortlog
-----------------
parent 609237ba
Loading
Loading
Loading
Loading
+9 −4
Original line number Diff line number Diff line
@@ -145,12 +145,17 @@ set(_pkg_config_private_reqs)
set(_pkg_config_libs)
set(_pkg_config_private_libs)

check_function_exists(sqrt HAVE_SQRT)
include(CheckCSourceCompiles)
set(LIBM_TEST_SOURCE "#include<math.h>\nfloat f; int main(){sqrt(f);return 0;}")
check_c_source_compiles("${LIBM_TEST_SOURCE}" HAVE_MATH)
if(NOT HAVE_SQRT)
  check_library_exists(m sqrt "" HAVE_LIBM_SQRT)
  if(NOT HAVE_LIBM_SQRT)
    message(FATAL_ERROR "Unable to use C math library functions (with or without -lm)")
  set(CMAKE_REQUIRED_LIBRARIES m)
  check_c_source_compiles("${LIBM_TEST_SOURCE}" HAVE_LIBM_MATH)
  unset(CMAKE_REQUIRED_LIBRARIES)
  if(NOT HAVE_LIBM_MATH)
    message(FATAL_ERROR "Unable to use C math library functions")
  endif()
    
  target_link_libraries(EVPath PRIVATE m)
  list(APPEND _pkg_config_private_libs m)
endif()
+1 −1
Original line number Diff line number Diff line
@@ -683,7 +683,7 @@ libcmenet_LTX_non_blocking_listen(CManager cm, CMtrans_services svc,
	/* we're already listening */
        if (port_num == 0) {
	    /* not requesting a specific port, return what we have */
	    return build_listen_attrs(cm, svc, NULL, listen_info, address.port);
	    return build_listen_attrs(cm, svc, NULL, listen_info, enet_data->listen_port);
	} else {
	    printf("CMlisten_specific() requesting a specific port follows other Enet operation which initiated listen at another port.  Only one listen allowed, second listen fails.\n");
	    return NULL;
+11 −0
Original line number Diff line number Diff line
@@ -324,6 +324,17 @@ CMConnection_close (CMConnection conn);
extern void
CMConnection_add_reference (CMConnection conn);

/*!
 * manually decrement the reference count of a connection.
 *
 * \param conn the CMConnection whose count should be decremented.
 * \note  Used if some mechanism other than CMget_conn() is used to "share"
 * connection in multiple contexts so that it is closed only when all users
 * have closed it.
*/
extern void
CMConnection_dereference (CMConnection conn);

/*!
 * register a function to be called when a connection is closed.
 *