[ofa-general] [PATCH 2/2] [uDAPL v1] fix openib_scm compiler warning

Patrick Marchand Latifi patrick.latifi at qlogic.com
Fri Mar 14 14:30:20 PDT 2008


Cast to socklen_t since accept(2) expects an unsigned argument.

Makes the openib_scm provider now build successfully when using
make VERBS=<provider> (the -Werror flag was causing the build
failure)

Signed-off-by: Patrick Marchand Latifi <patrick.latifi at qlogic.com>
---

 dapl/openib_scm/dapl_ib_cm.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/dapl/openib_scm/dapl_ib_cm.c b/dapl/openib_scm/dapl_ib_cm.c
index ea75453..f534e8d 100644
--- a/dapl/openib_scm/dapl_ib_cm.c
+++ b/dapl/openib_scm/dapl_ib_cm.c
@@ -347,7 +347,7 @@ dapli_socket_accept(ib_cm_srvc_handle_t cm_ptr)
 	len = sizeof(acm_ptr->dst.ia_address);
 	acm_ptr->socket = accept(cm_ptr->l_socket, 
 				(struct sockaddr*)&acm_ptr->dst.ia_address, 
-				&len );
+				(socklen_t*)&len );
 
 	if ( acm_ptr->socket < 0 ) {
 		dapl_dbg_log(DAPL_DBG_TYPE_ERR, 




More information about the general mailing list