[Home]

Summary:ASTERISK-07513: [patch] not stop asterisk load when not configuring
Reporter:Denis Smirnov (mithraen)Labels:
Date Opened:2006-08-10 18:10:04Date Closed:2006-08-16 14:14:39
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Channels/chan_misdn
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) chan_misdn.not.die.patch
Description:I think that stopping asterisk starting if chan_misdn loaded, but misdn not configured is a bad idea.
Comments:By: crich (crich) 2006-08-11 01:41:03

yeah you're right, the patch would not stop asterisk. But the users might oversee the Message that mISDN could not be initialized when asterisk goes on, and then they would wonder why their ISDN Lines do not work.. Stopping asterisk make it perfectly clear what was wrong.

I wonder how chan_zap behaves in this situation?

By: crich (crich) 2006-08-11 01:47:16

that is what happens in chan_zap:

load_module()
{
....
      res = setup_zap(0);
       /* Make sure we can register our Zap channel type */
       if (res)
               return -1;
....
}


I sort of copied the behaviour.

By: Denis Smirnov (mithraen) 2006-08-11 09:23:30

But it stop using asterisk, if chan_misdn accidently installed but not used.

Look in setup_zap in chan_zap.c:

   cfg = ast_config_load(config);

   /* Error if we have no config file */
   if (!cfg) {
       ast_log(LOG_ERROR, "Unable to load config %s\n", config);
       return 0;
   }

If zapata.conf not exists, chan_zap not stop asterisk start.

By: Denis Smirnov (mithraen) 2006-08-16 14:04:08



By: crich (crich) 2006-08-16 14:14:10

added the patch to trunk.