diff options
author | fcolin | 2007-02-01 13:03:14 +0000 |
---|---|---|
committer | fcolin | 2007-02-01 13:03:14 +0000 |
commit | 828345b232bd03acc670731a8a1e8b04e93fa528 (patch) | |
tree | 1557082b6a7188989625297af304dcabd408fd53 | |
parent | d3034a30db643cefc90b690a422b98dd7b2a0713 (diff) | |
download | ivy-cplusplus-828345b232bd03acc670731a8a1e8b04e93fa528.zip ivy-cplusplus-828345b232bd03acc670731a8a1e8b04e93fa528.tar.gz ivy-cplusplus-828345b232bd03acc670731a8a1e8b04e93fa528.tar.bz2 ivy-cplusplus-828345b232bd03acc670731a8a1e8b04e93fa528.tar.xz |
Utilisateur : Fcolin Date : 5/11/02 Heure : 9:57 Archivé dans $/Bus/Ivy Commentaire: (vss 8)
-rw-r--r-- | Ivy/IvySynchroWnd.cxx | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/Ivy/IvySynchroWnd.cxx b/Ivy/IvySynchroWnd.cxx index e2b2338..cabe92c 100644 --- a/Ivy/IvySynchroWnd.cxx +++ b/Ivy/IvySynchroWnd.cxx @@ -117,6 +117,11 @@ IvySynchronousMessageCallback::IvySynchronousMessageCallback( IvyMessageCallback IvySynchronousMessageCallback::~IvySynchronousMessageCallback()
{
//delete target;
+ for( int i = 0; i < argc ; i++ )
+ {
+ delete argv[i];
+ }
+ if ( argv ) delete argv;
}
void IvySynchronousMessageCallback::OnMessage(IvyApplication *app, int argc, const char **argv )
{
@@ -128,8 +133,7 @@ void IvySynchronousMessageCallback::OnMessage(IvyApplication *app, int argc, con param->argv = new char*[argc];
for( int i = 0; i < argc ; i++ )
{
- param->argv[i] = new char[ strlen( argv[i]) +1 ];
- strcpy( param->argv[i], argv[i]);
+ param->argv[i] = strdup( argv[i]);
}
// TRACE( "IvySynchronousMessageCallback::OnMessage msg count %d\n",wParam);
m_synchro->PostIvyCB( param );
|