Fixed some minor bugs in config.c.
This commit is contained in:
@@ -2096,7 +2096,7 @@ config_set_int(char *head, char *name, int val)
|
|||||||
ent = create_entry(section, name);
|
ent = create_entry(section, name);
|
||||||
|
|
||||||
sprintf(ent->data, "%i", val);
|
sprintf(ent->data, "%i", val);
|
||||||
mbstowcs(ent->wdata, ent->data, sizeof_w(ent->wdata));
|
mbstowcs(ent->wdata, ent->data, sizeof(ent->wdata));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -2115,7 +2115,7 @@ config_set_hex16(char *head, char *name, int val)
|
|||||||
ent = create_entry(section, name);
|
ent = create_entry(section, name);
|
||||||
|
|
||||||
sprintf(ent->data, "%04X", val);
|
sprintf(ent->data, "%04X", val);
|
||||||
mbstowcs(ent->wdata, ent->data, sizeof_w(ent->wdata));
|
mbstowcs(ent->wdata, ent->data, sizeof(ent->wdata));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -2173,7 +2173,7 @@ config_set_string(char *head, char *name, char *val)
|
|||||||
ent = create_entry(section, name);
|
ent = create_entry(section, name);
|
||||||
|
|
||||||
memcpy(ent->data, val, sizeof(ent->data));
|
memcpy(ent->data, val, sizeof(ent->data));
|
||||||
mbstowcs(ent->wdata, ent->data, sizeof_w(ent->wdata));
|
mbstowcs(ent->wdata, ent->data, sizeof(ent->wdata));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user