Changeset 3336
- Timestamp:
- Oct 11, 2010 10:59:37 AM (14 years ago)
- Location:
- pjproject/trunk/pjlib
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjlib/include/pj/activesock.h
r3299 r3336 317 317 PJ_DECL(void) pj_activesock_set_iphone_os_bg(pj_activesock_t *asock, 318 318 int val); 319 320 /** 321 * Enable/disable support for iPhone OS background mode. This setting 322 * will apply globally and will affect any active sockets created 323 * afterwards, if you want to change the setting for a particular 324 * active socket, use #pj_activesock_set_iphone_os_bg() instead. 325 * By default, this setting is enabled. 326 * 327 * @param val The value of global background mode setting. 328 * 329 */ 330 PJ_DECL(void) pj_activesock_enable_iphone_os_bg(pj_bool_t val); 319 331 #endif 320 332 -
pjproject/trunk/pjlib/src/pj/activesock.c
r3317 r3336 30 30 PJ_IPHONE_OS_HAS_MULTITASKING_SUPPORT!=0 31 31 # include <CFNetwork/CFNetwork.h> 32 33 static pj_bool_t ios_bg_support = PJ_TRUE; 32 34 #endif 33 35 … … 134 136 static void activesock_create_iphone_os_stream(pj_activesock_t *asock) 135 137 { 136 if ( asock->bg_setting && asock->stream_oriented) {138 if (ios_bg_support && asock->bg_setting && asock->stream_oriented) { 137 139 activesock_destroy_iphone_os_stream(asock); 138 140 … … 164 166 else 165 167 activesock_destroy_iphone_os_stream(asock); 168 } 169 170 PJ_DEF(void) pj_activesock_enable_iphone_os_bg(pj_bool_t val) 171 { 172 ios_bg_support = val; 166 173 } 167 174 #endif
Note: See TracChangeset
for help on using the changeset viewer.