try to fix bug
This commit is contained in:
parent
29bdc52efa
commit
c52c3c2a9b
@ -704,7 +704,7 @@ static char *www_wordwrap(char *content, int cutoff) {
|
||||
int i;
|
||||
int line_count = 0;
|
||||
char *last_space = NULL;
|
||||
char *ret = (char *)malloc(len + 1);
|
||||
char *ret;
|
||||
int at = 0;
|
||||
int extra = 0;
|
||||
if (ret == NULL) {
|
||||
@ -727,6 +727,8 @@ static char *www_wordwrap(char *content, int cutoff) {
|
||||
content[at] = '\0';
|
||||
at = 0;
|
||||
|
||||
len = strlen(content);
|
||||
ret = (char *)malloc(len + 1);
|
||||
for (i=0;i<len;i++) {
|
||||
if (content[i] == '\n') {
|
||||
continue;
|
||||
|
Reference in New Issue
Block a user