mirror of
				https://github.com/asterisk/asterisk.git
				synced 2025-10-31 18:55:19 +00:00 
			
		
		
		
	allow netsock objects to be unref'd so they can disappear when needed (issue #5454)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6913 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
		| @@ -8640,6 +8640,7 @@ static int set_config(char *config_file, int reload) | ||||
| 					} | ||||
| 					if (defaultsockfd < 0)  | ||||
| 						defaultsockfd = ast_netsock_sockfd(ns); | ||||
| 					ast_netsock_unref(ns); | ||||
| 				} | ||||
| 			} | ||||
| 		} else if (!strcasecmp(v->name, "authdebug")) | ||||
| @@ -9568,6 +9569,7 @@ int load_module(void) | ||||
| 			if (option_verbose > 1) | ||||
| 				ast_verbose(VERBOSE_PREFIX_2 "Binding IAX2 to default address 0.0.0.0:%d\n", IAX_DEFAULT_PORTNO); | ||||
| 			defaultsockfd = ast_netsock_sockfd(ns); | ||||
| 			ast_netsock_unref(ns); | ||||
| 		} | ||||
| 	} | ||||
| 	 | ||||
|   | ||||
| @@ -59,6 +59,8 @@ const struct sockaddr_in *ast_netsock_boundaddr(const struct ast_netsock *ns); | ||||
|  | ||||
| void *ast_netsock_data(const struct ast_netsock *ns); | ||||
|  | ||||
| void ast_netsock_unref(struct ast_netsock *ns); | ||||
|  | ||||
| #if defined(__cplusplus) || defined(c_plusplus) | ||||
| } | ||||
| #endif | ||||
|   | ||||
		Reference in New Issue
	
	Block a user