config_parser: don't use sizeof(char)
This commit is contained in:
parent
c85d16faa4
commit
fa4f1c5b0f
|
@ -931,7 +931,7 @@ bool parse_file(const char *f, bool use_nagbar) {
|
||||||
/* Then, allocate a new buffer and copy the file over to the new one,
|
/* Then, allocate a new buffer and copy the file over to the new one,
|
||||||
* but replace occurences of our variables */
|
* but replace occurences of our variables */
|
||||||
char *walk = buf, *destwalk;
|
char *walk = buf, *destwalk;
|
||||||
char *new = smalloc((stbuf.st_size + extra_bytes + 1) * sizeof(char));
|
char *new = smalloc(stbuf.st_size + extra_bytes + 1);
|
||||||
destwalk = new;
|
destwalk = new;
|
||||||
while (walk < (buf + stbuf.st_size)) {
|
while (walk < (buf + stbuf.st_size)) {
|
||||||
/* Find the next variable */
|
/* Find the next variable */
|
||||||
|
|
Loading…
Reference in New Issue