9
0
Fork 0

svn_rev_622

ups
This commit is contained in:
Sascha Hauer 2007-07-05 18:02:10 +02:00 committed by Sascha Hauer
parent 7e77a890ca
commit df22d58390
1 changed files with 2 additions and 2 deletions

View File

@ -152,7 +152,7 @@ static struct line *line_realloc(int len, struct line *line)
line->data = malloc(32);
}
while(size < len)
while (size < len)
size <<= 1;
line->data = realloc(line->data, size);
@ -182,7 +182,7 @@ static int edit_read_file(const char *path)
if (!r && tmp == rbuf)
break;
*tmp = 0;
line = line_realloc(strlen(rbuf + 1), NULL);
line = line_realloc(strlen(rbuf) + 1, NULL);
if (!buffer)
buffer = line;
memcpy(line->data, rbuf, strlen(rbuf) + 1);