Browse code

dmq_usrloc: use new version of serialized structure returned by usrloc (now includes received address)

Charles Chance authored on 15/07/2015 08:48:57
Showing 1 changed files
... ...
@@ -96,7 +96,7 @@ void usrloc_get_all_ucontact(dmq_node_t* node)
96 96
 {
97 97
  	int rval, len=0;
98 98
 	void *buf, *cp;
99
-	str c;
99
+	str c, recv;
100 100
 	str path;
101 101
 	str ruid;
102 102
 	unsigned int aorhash;
... ...
@@ -145,6 +145,9 @@ void usrloc_get_all_ucontact(dmq_node_t* node)
145 145
             break;
146 146
         c.s = (char*)cp + sizeof(c.len);
147 147
         cp =  (char*)cp + sizeof(c.len) + c.len;
148
+        memcpy(&(recv.len), cp, sizeof(recv.len));
149
+        recv.s = (char*)cp + sizeof(recv.len);
150
+        cp =  (char*)cp + sizeof(recv.len) + recv.len;
148 151
         memcpy( &send_sock, cp, sizeof(send_sock));
149 152
         cp = (char*)cp + sizeof(send_sock);
150 153
         memcpy( &flags, cp, sizeof(flags));