get_lid_from_name(): Remove an unused variable
PATCH 1/1 get_lid_from_name(): Remove an unused variable
This patch avoids that the following compiler warning is triggered:
src/saquery.c:869:18: warning: variable 'p_ni' set but not used [-Wunused-but-set-variable]
Signed-off-by Bart Van Assche <[email protected]>
--- src/saquery.c | 2 -- 1 file changed, 2 deletions(-)
src/saquery.c +0 -2
@@ -866,7 +866,6 @@ static int get_and_dump_all_records(struct sa_handle * h, uint16_t attr_id,static int get_lid_from_name (struct sa_handle * h,const char *name,uint16_t * lid) {ib_node_record_t *node_record =NULL ; -ib_node_info_t *p_ni =NULL ;unsigned i;int ret;struct sa_query_result result;
@@ -878,7 +877,6 @@ static int get_lid_from_name(struct sa_handle * h, const char *name, uint16_t * ret =ENONET ; for (i = 0; i < result.result_cnt; i++) { node_record = sa_get_query_rec(result.p_result_madw, i); - p_ni = &(node_record->node_info); if (name && strncmp(name, (char *)node_record->node_desc.description, sizeof(node_record->node_desc.description)) ==
Signature · 6 lines
1.7.10.4 -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): [email protected]
Ira Weiny
AppliedQuoted 5 lines · On Sun, 18 Aug 2013 10:57:07 +0200 Bart Van Assche…
This patch avoids that the following compiler warning is triggered:
src/saquery.c:869:18: warning: variable 'p_ni' set but not used [-Wunused-but-set-variable]Signed-off-by Bart Van Assche <[email protected]>
Thanks applied,
Ira
Quoted 27 lines
--- src/saquery.c | 2 -- 1 file changed, 2 deletions(-)src/saquery.c +0
-2@@ -866,7 +866,6 @@ static int get_and_dump_all_records(struct sa_handle * h, uint16_t attr_id,static int get_lid_from_name (struct sa_handle * h,const char *name,uint16_t * lid) {ib_node_record_t *node_record =NULL ; -ib_node_info_t *p_ni =NULL ;unsigned i;int ret;struct sa_query_result result;@@ -878,7 +877,6 @@ static int get_lid_from_name(struct sa_handle * h, const char *name, uint16_t * ret =ENONET ; for (i = 0; i < result.result_cnt; i++) { node_record = sa_get_query_rec(result.p_result_madw, i); - p_ni = &(node_record->node_info); if (name && strncmp(name, (char *)node_record->node_desc.description, sizeof(node_record->node_desc.description)) ==Signature · 1 line
1.7.10.4
Signature · 5 lines
Ira Weiny <[email protected]> -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html