Messing with wordwrap
This commit is contained in:
parent
759b5a3adb
commit
0ebdbe71b4
@ -763,6 +763,7 @@ static char *www_wordwrap(char *content, int cutoff) {
|
||||
int at = 0;
|
||||
int extra = 0;
|
||||
int quote_line = 0;
|
||||
int z;
|
||||
|
||||
for (i=0;i<len;i++) {
|
||||
if (content[i] == '\n') {
|
||||
@ -786,7 +787,8 @@ static char *www_wordwrap(char *content, int cutoff) {
|
||||
line_count = 0;
|
||||
quote_line = 0;
|
||||
} else if (quote_line != 1) {
|
||||
if (at > 0 && content[at-1] != '\r' && content[at-1] != ' ') {
|
||||
for (z = i+1;content[z] != ' ' && z < len;z++);
|
||||
if (at > 0 && content[at-1] != '\r' && content[at-1] != ' ' && cutoff - line_count < z) {
|
||||
content[at++] = ' ';
|
||||
line_count++;
|
||||
}
|
||||
|
Reference in New Issue
Block a user