[wsd] Fix a bug for the IA64 processor (based on patch from stan.smith@intel.com)
authortzachid <tzachid@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Thu, 6 Sep 2007 09:07:27 +0000 (09:07 +0000)
committertzachid <tzachid@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Thu, 6 Sep 2007 09:07:27 +0000 (09:07 +0000)
git-svn-id: svn://openib.tc.cornell.edu/gen1/trunk@780 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86

ulp/wsd/user/ibsp_ip.c

index 6fb1e2c..2a2da82 100644 (file)
@@ -155,10 +155,11 @@ query_ip_address(
                        IBSP_ERROR_EXIT( ("no memory\n") );\r
                        break;\r
                }\r
+               /* Copy the IP address being ia64 friendly */\r
+               memcpy( (void*)&ip_addr->ip_addr.S_un.S_addr,\r
+                               (void*)&p_out->Address[i].Address[ATS_IPV4_OFFSET],\r
+                               sizeof(ib_net32_t) );\r
 \r
-               /* Copy the IP address */\r
-               ip_addr->ip_addr.S_un.S_addr =\r
-                       *(ib_net32_t *) &p_out->Address[i].Address[ATS_IPV4_OFFSET];\r
                ip_addr->p_port = p_port;\r
 \r
                p_item = cl_fmap_insert( p_ip_map, ip_addr, &ip_addr->item );\r