summaryrefslogtreecommitdiff
path: root/src/map/itemdb.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/map/itemdb.c')
-rw-r--r--src/map/itemdb.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/map/itemdb.c b/src/map/itemdb.c
index f1cbdb3f5..2d4e9a3af 100644
--- a/src/map/itemdb.c
+++ b/src/map/itemdb.c
@@ -212,7 +212,7 @@ static void itemdb_jobid2mapid(unsigned int *bclass, unsigned int jobmask)
}
static void create_dummy_data(void) {
- malloc_set(&dummy_item, 0, sizeof(struct item_data));
+ memset(&dummy_item, 0, sizeof(struct item_data));
dummy_item.nameid=500;
dummy_item.weight=1;
dummy_item.value_sell = 1;
@@ -431,7 +431,7 @@ static int itemdb_read_itemavail (void)
while (fgets(line, sizeof(line) - 1, fp)) {
if (line[0] == '/' && line[1] == '/')
continue;
- malloc_tsetdword(str, 0, sizeof(str));
+ memset(str, 0, sizeof(str));
for (j = 0, p = line; j < 2 && p; j++) {
str[j] = p;
p = strchr(p, ',');
@@ -485,7 +485,7 @@ static void itemdb_read_itemgroup_sub(const char* filename)
continue;
}
}
- malloc_tsetdword(str,0,sizeof(str));
+ memset(str,0,sizeof(str));
for(j=0,p=line;j<3 && p;j++){
str[j]=p;
p=strchr(p,',');
@@ -561,7 +561,7 @@ static void itemdb_read_itemgroup(void)
"Gift Box China",
"Lotto Box",
};
- malloc_tsetdword(&itemgroup_db, 0, sizeof(itemgroup_db));
+ memset(&itemgroup_db, 0, sizeof(itemgroup_db));
snprintf(path, 255, "%s/item_group_db.txt", db_path);
itemdb_read_itemgroup_sub(path);
ShowStatus("Done reading '"CL_WHITE"%s"CL_RESET"'.\n","item_group_db.txt");
@@ -739,7 +739,7 @@ static int itemdb_read_noequip(void)
while(fgets(line,1020,fp)){
if(line[0]=='/' && line[1]=='/')
continue;
- malloc_tsetdword(str,0,sizeof(str));
+ memset(str,0,sizeof(str));
for(j=0,p=line;j<2 && p;j++){
str[j]=p;
p=strchr(p,',');
@@ -784,7 +784,7 @@ static int itemdb_read_itemtrade(void)
while (fgets(line, sizeof(line) - 1, fp)) {
if (line[0] == '/' && line[1] == '/')
continue;
- malloc_tsetdword(str, 0, sizeof(str));
+ memset(str, 0, sizeof(str));
for (j = 0, p = line; j < 3 && p; j++) {
str[j] = p;
p = strchr(p, ',');
@@ -1039,7 +1039,7 @@ static int itemdb_readdb(void)
lines++;
if(line[0]=='/' && line[1]=='/')
continue;
- malloc_tsetdword(str,0,sizeof(str));
+ memset(str,0,sizeof(str));
for(j=0,np=p=line;j<19 && p;j++){
str[j]=p;
p=strchr(p,',');