[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Ayttm-commits] CVS: ayttm/modules/msn2 msn.C,1.6,1.7
From: |
Colin Leroy <address@hidden> |
Subject: |
[Ayttm-commits] CVS: ayttm/modules/msn2 msn.C,1.6,1.7 |
Date: |
Sat, 04 Jan 2003 04:04:51 -0500 |
Update of /cvsroot/ayttm/ayttm/modules/msn2
In directory subversions:/tmp/cvs-serv2475/modules/msn2
Modified Files:
msn.C
Log Message:
Valgrinding around
Index: msn.C
===================================================================
RCS file: /cvsroot/ayttm/ayttm/modules/msn2/msn.C,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- msn.C 2 Jan 2003 07:11:09 -0000 1.6
+++ msn.C 4 Jan 2003 09:04:48 -0000 1.7
@@ -709,7 +709,7 @@
eb_local_account * eb_msn_read_local_account_config( GList * values )
{
char buff[255];
- char * c;
+ char * c = NULL;
eb_local_account * ela;
eb_msn_local_account_data * mlad;
@@ -720,9 +720,11 @@
ela = g_new0(eb_local_account,1);
mlad = g_new0( eb_msn_local_account_data, 1);
- ela->handle = strdup( value_pair_get_value( values, "SCREEN_NAME" ));
- strcpy( mlad->password, value_pair_get_value( values, "PASSWORD") );
-
+ ela->handle = value_pair_get_value( values, "SCREEN_NAME" );
+ c = value_pair_get_value( values, "PASSWORD");
+ strcpy( mlad->password, c);
+ g_free (c); c = NULL;
+
/*the alias will be the persons login minus the @hotmail.com */
strcpy( buff, ela->handle );
c = strtok( buff, "@" );
@@ -758,11 +760,14 @@
eb_account * eb_msn_read_account_config( GList * config, struct contact *
contact)
{
+ char *tmp = NULL;
eb_account * ea = g_new0(eb_account, 1);
eb_msn_account_data * mad = g_new0( eb_msn_account_data, 1 );
mad->status = MSN_OFFLINE;
- strncpy(ea->handle, value_pair_get_value( config, "NAME"), 255 );
+ tmp = value_pair_get_value( config, "NAME");
+ strncpy(ea->handle, tmp, 255 );
+ g_free(tmp);
ea->service_id = SERVICE_INFO.protocol_id;
ea->protocol_account_data = mad;
@@ -1553,7 +1558,7 @@
/* handle utf8 */
if (msg->content != NULL && !strcmp(msg->content, "text/plain;
charset=UTF-8"))
- msg->body = g_strdup (Utf8ToStr (msg->body));
+ msg->body = Utf8ToStr (msg->body);
/* The username element is always valid, even if it's not an SB */
local_account_name=((authdata_SB *)conn->auth)->username;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Ayttm-commits] CVS: ayttm/modules/msn2 msn.C,1.6,1.7,
Colin Leroy <address@hidden> <=
- Prev by Date:
[Ayttm-commits] CVS: ayttm/modules/utility autotrans.c,1.2,1.3 notes.c,1.2,1.3 rainbow.c,1.2,1.3
- Next by Date:
[Ayttm-commits] CVS: ayttm ChangeLog,1.28,1.29 config.h.in,1.1.1.1,1.2 configure.in,1.28,1.29
- Previous by thread:
[Ayttm-commits] CVS: ayttm/modules/utility autotrans.c,1.2,1.3 notes.c,1.2,1.3 rainbow.c,1.2,1.3
- Next by thread:
[Ayttm-commits] CVS: ayttm ChangeLog,1.28,1.29 config.h.in,1.1.1.1,1.2 configure.in,1.28,1.29
- Index(es):