Changeset 1888 for pjproject/trunk
- Timestamp:
- Mar 22, 2008 9:33:26 AM (17 years ago)
- Location:
- pjproject/trunk/pjnath
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjnath/include/pjnath/stun_msg.h
r1885 r1888 873 873 /** 874 874 * Get 16bit channel number from 32bit integral value. 875 * Note that uint32 attributes are always stored in host byte order 876 * after they have been parsed from the PDU, so no need to do ntohs() 877 * here. 875 878 */ 876 879 #define PJ_STUN_GET_CH_NB(u32) ((pj_uint16_t)(u32>>16)) … … 878 881 /** 879 882 * Convert 16bit channel number into 32bit integral value. 883 * Note that uint32 attributes will be converted to network byte order 884 * when the attribute is written to packet, so no need to do htons() 885 * here. 880 886 */ 881 887 #define PJ_STUN_SET_CH_NB(chnum) (((pj_uint32_t)chnum) << 16) -
pjproject/trunk/pjnath/src/pjturn-client/client_main.c
r1882 r1888 191 191 while (!g.quit) { 192 192 const pj_time_val delay = {0, 10}; 193 int i ;193 int i, n=0; 194 194 pj_fd_set_t readset; 195 195 … … 204 204 for (i=0; i<PJ_ARRAY_SIZE(g.peer); ++i) { 205 205 PJ_FD_SET(g.peer[i].sock, &readset); 206 if (g.peer[i].sock > n) 207 n = g.peer[i].sock; 206 208 } 207 209 208 if (pj_sock_select( 64, &readset, NULL, NULL, &delay) <= 0)210 if (pj_sock_select(n+1, &readset, NULL, NULL, &delay) <= 0) 209 211 continue; 210 212
Note: See TracChangeset
for help on using the changeset viewer.