You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by sa...@apache.org on 2005/07/28 07:39:07 UTC
cvs commit: ws-axis/c/src/transport/axis3 ChannelFactory.cpp
samisa 2005/07/27 22:39:07
Modified: c/src/transport/axis3 ChannelFactory.cpp
Log:
It seemed to me that the channel was not being properly deleted and caused memory leaks.
I added logic to delete the channel
AXISCPP-674
Revision Changes Path
1.19 +8 -2 ws-axis/c/src/transport/axis3/ChannelFactory.cpp
Index: ChannelFactory.cpp
===================================================================
RCS file: /home/cvs/ws-axis/c/src/transport/axis3/ChannelFactory.cpp,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -r1.18 -r1.19
--- ChannelFactory.cpp 28 Jun 2005 09:03:59 -0000 1.18
+++ ChannelFactory.cpp 28 Jul 2005 05:39:07 -0000 1.19
@@ -158,11 +158,17 @@
// in turn calls the channel destructor. On return from this call, the
// m_pChannel[iLibIndex] object no longer exists.
DELETE_OBJECT3 sDelete = (DELETE_OBJECT3) PLATFORM_GETPROCADDR( m_LibHandler[iLibIndex], DELETE_FUNCTION3);
-
sDelete( m_pChannel[iLibIndex]);
}
+ else
+ {
+ // Samisa: somehow, the above block does not seem to deallocate the channel
+ // As a workaround, I delete the channel here and seems this logic is not having any side effects
+ // More importantly I could get rid of the memory leak
+ delete m_pChannel[iLibIndex];
+ }
- m_pChannel[iLibIndex] = 0;
+ m_pChannel[iLibIndex] = NULL;
}
// Delete library name from the library name list.