Merged revisions 255322 via svnmerge from
authorRussell Bryant <russell@russellbryant.com>
Tue, 30 Mar 2010 16:07:49 +0000 (16:07 +0000)
committerRussell Bryant <russell@russellbryant.com>
Tue, 30 Mar 2010 16:07:49 +0000 (16:07 +0000)
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r255322 | russell | 2010-03-30 11:06:06 -0500 (Tue, 30 Mar 2010) | 2 lines

  Don't make Asterisk not start if pbx_dundi fails to initialize.
........

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@255323 65c4cc65-6c06-0410-ace0-fbb531ad65f3

pbx/pbx_dundi.c

index af17c46..3aa1700 100644 (file)
@@ -4837,7 +4837,7 @@ static int load_module(void)
        sched = sched_context_create();
 
        if (!io || !sched)
-               return AST_MODULE_LOAD_FAILURE;
+               return AST_MODULE_LOAD_DECLINE;
 
        if (set_config("dundi.conf", &sin, 0))
                return AST_MODULE_LOAD_DECLINE;
@@ -4846,12 +4846,12 @@ static int load_module(void)
 
        if (netsocket < 0) {
                ast_log(LOG_ERROR, "Unable to create network socket: %s\n", strerror(errno));
-               return AST_MODULE_LOAD_FAILURE;
+               return AST_MODULE_LOAD_DECLINE;
        }
        if (bind(netsocket, (struct sockaddr *) &sin, sizeof(sin))) {
                ast_log(LOG_ERROR, "Unable to bind to %s port %d: %s\n",
                        ast_inet_ntoa(sin.sin_addr), ntohs(sin.sin_port), strerror(errno));
-               return AST_MODULE_LOAD_FAILURE;
+               return AST_MODULE_LOAD_DECLINE;
        }
 
        ast_netsock_set_qos(netsocket, tos, 0, "DUNDi");
@@ -4859,7 +4859,7 @@ static int load_module(void)
        if (start_network_thread()) {
                ast_log(LOG_ERROR, "Unable to start network thread\n");
                close(netsocket);
-               return AST_MODULE_LOAD_FAILURE;
+               return AST_MODULE_LOAD_DECLINE;
        }
 
        ast_cli_register_multiple(cli_dundi, ARRAY_LEN(cli_dundi));