From 4db583138b9556f72b13df7f66eeeace6a67ce3e Mon Sep 17 00:00:00 2001 From: Lance Date: Sat, 29 Apr 2006 04:00:19 +0000 Subject: * Using malloc for memory allocations that doesn't need to be pre-initialized. * Eliminated initializations for pointers returned by calloc. * Moved grfio_final to do_init since it's not used after server boot. * Optimized scripts to return CONSTSTR instead of allocating memory just to return a constant string. Some buildin functions still need work. * Disabled graph since it doesn't work yet. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@6355 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/map/chrif.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/map/chrif.c') diff --git a/src/map/chrif.c b/src/map/chrif.c index 373808cc7..939208e8e 100644 --- a/src/map/chrif.c +++ b/src/map/chrif.c @@ -465,7 +465,7 @@ void chrif_authreq(struct map_session_data *sd) aFree(auth_data->char_dat); idb_remove(auth_db, sd->bl.id); } else { //data from char server has not arrived yet. - auth_data = aCalloc(1, sizeof(struct auth_node)); + auth_data = aMalloc(sizeof(struct auth_node)); auth_data->sd = sd; auth_data->fd = sd->fd; auth_data->account_id = sd->bl.id; @@ -511,8 +511,8 @@ void chrif_authok(int fd) { return; } // Awaiting for client to connect. - auth_data = (struct auth_node *)aCalloc(1, sizeof(struct auth_node)); - auth_data->char_dat = (struct mmo_charstatus *) aCalloc(1, sizeof(struct mmo_charstatus)); + auth_data = (struct auth_node *)aMalloc(sizeof(struct auth_node)); + auth_data->char_dat = (struct mmo_charstatus *) aCalloc(1,sizeof(struct mmo_charstatus)); auth_data->account_id=RFIFOL(fd, 4); auth_data->login_id1=RFIFOL(fd, 8); -- cgit v1.2.3-70-g09d2