[ofa-general] [PATCH v2] opensm: fix build warning with --disable-console-socket

Sasha Khapyorsky sashak at voltaire.com
Mon Mar 9 07:24:53 PDT 2009


Fix OpenSM build warning - when configured with '--disable-console-socket'
console_close() ibecomes unused.

Signed-off-by: Sasha Khapyorsky <sashak at voltaire.com>
---
 opensm/opensm/osm_console_io.c |    5 -----
 1 files changed, 0 insertions(+), 5 deletions(-)

diff --git a/opensm/opensm/osm_console_io.c b/opensm/opensm/osm_console_io.c
index b0a8356..606b6f1 100644
--- a/opensm/opensm/osm_console_io.c
+++ b/opensm/opensm/osm_console_io.c
@@ -106,12 +106,10 @@ int cio_close(osm_console_t * p_oct)
 	}
 	return rtnval;
 }
-#endif
 
 /* close the connection */
 static void console_close(osm_console_t * p_oct, osm_log_t * p_log)
 {
-#ifdef ENABLE_OSM_CONSOLE_SOCKET
 	if ((p_oct->socket > 0) && (p_oct->in_fd != -1)) {
 		OSM_LOG(p_log, OSM_LOG_INFO,
 			"Console connection closed: %s (%s)\n",
@@ -122,14 +120,11 @@ static void console_close(osm_console_t * p_oct, osm_log_t * p_log)
 		close(p_oct->socket);
 		p_oct->socket = -1;
 	}
-#endif
 }
 
-
 /**********************************************************************
  * Do authentication & authorization check
  **********************************************************************/
-#ifdef ENABLE_OSM_CONSOLE_SOCKET
 int is_authorized(osm_console_t * p_oct)
 {
 	/* allowed to use the console? */
-- 
1.6.1.2.319.gbd9e




More information about the general mailing list