[asterisk-commits] pcadach: branch pcadach/chan_h323-live r42860 -
/team/pcadach/chan_h323-live/...
asterisk-commits at lists.digium.com
asterisk-commits at lists.digium.com
Tue Sep 12 13:49:57 MST 2006
Author: pcadach
Date: Tue Sep 12 15:49:56 2006
New Revision: 42860
URL: http://svn.digium.com/view/asterisk?rev=42860&view=rev
Log:
Process shutdowns in correct order
Modified:
team/pcadach/chan_h323-live/channels/h323/ast_h323.cpp
Modified: team/pcadach/chan_h323-live/channels/h323/ast_h323.cpp
URL: http://svn.digium.com/view/asterisk/team/pcadach/chan_h323-live/channels/h323/ast_h323.cpp?rev=42860&r1=42859&r2=42860&view=diff
==============================================================================
--- team/pcadach/chan_h323-live/channels/h323/ast_h323.cpp (original)
+++ team/pcadach/chan_h323-live/channels/h323/ast_h323.cpp Tue Sep 12 15:49:56 2006
@@ -145,10 +145,23 @@
#define cout (*logstream)
+/* Special class designed to call cleanup code on module destruction */
+class MyH323_Shutdown {
+ public:
+ MyH323_Shutdown() { };
+ ~MyH323_Shutdown()
+ {
+ h323_end_process();
+ };
+};
+
MyProcess::MyProcess(): PProcess("The NuFone Network's",
"H.323 Channel Driver for Asterisk",
MAJOR_VERSION, MINOR_VERSION, BUILD_TYPE, BUILD_NUMBER)
{
+ /* Call shutdown when module being unload or asterisk has been stopped */
+ static MyH323_Shutdown x;
+
/* Fix missed one in PWLib */
PX_firstTimeStart = FALSE;
Resume();
@@ -1393,19 +1406,6 @@
return FALSE;
}
-/* Special class designed to call cleanup code on module destruction */
-class MyH323_Shutdown {
- public:
- MyH323_Shutdown() { };
- ~MyH323_Shutdown()
- {
- if (endPoint)
- endPoint->RemoveGatekeeper();
-#if 0
- h323_end_process();
-#endif
- };
-};
/** IMPLEMENTATION OF C FUNCTIONS */
@@ -1426,9 +1426,6 @@
void h323_end_point_create(void)
{
- /* Call shutdown when module being unload */
- static MyH323_Shutdown x;
-
channelsOpen = 0;
logstream = new PAsteriskLog();
localProcess = new MyProcess();
More information about the asterisk-commits
mailing list