]> git.openfabrics.org - ~shefty/librdmacm.git/commitdiff
[1/4] acm: Remove the unused variable 'pri_path'
authorBart Van Assche <bvanassche@acm.org>
Sun, 28 Jul 2013 09:18:36 +0000 (11:18 +0200)
committerSean Hefty <sean.hefty@intel.com>
Tue, 30 Jul 2013 22:43:55 +0000 (15:43 -0700)
The variable 'pri_path' is assigned a value but is never used.
This triggers the following compiler warning:

src/acm.c:301:26: warning: variable 'pri_path' set but not used [-Wunused-but-set-variable]

Hence remove this variable.

Signed-off-by: Bart Van Assche <bvanassche@acm.org>
src/acm.c

index 04cddee126acd098bcdc130a2c2be7753ca73c20..49bda48fcdc2e83cf3198a5222631a96a25c7a21 100644 (file)
--- a/src/acm.c
+++ b/src/acm.c
@@ -297,7 +297,6 @@ static void ucma_ib_save_resp(struct rdma_addrinfo *rai, struct acm_msg *msg)
 {
        struct acm_ep_addr_data *ep_data;
        struct ibv_path_data *path_data = NULL;
-       struct ibv_path_record *pri_path = NULL;
        struct sockaddr_in *sin;
        struct sockaddr_in6 *sin6;
        int i, cnt, path_cnt = 0;
@@ -311,9 +310,6 @@ static void ucma_ib_save_resp(struct rdma_addrinfo *rai, struct acm_msg *msg)
                        if (!path_data)
                                path_data = (struct ibv_path_data *) ep_data;
                        path_cnt++;
-                       if (ep_data->flags |
-                           (IBV_PATH_FLAG_PRIMARY | IBV_PATH_FLAG_OUTBOUND))
-                               pri_path = &path_data[i].path;
                        break;
                case ACM_EP_INFO_ADDRESS_IP:
                        if (!(ep_data->flags & ACM_EP_FLAG_SOURCE) || rai->ai_src_len)