Fix internal editor quoting
This commit is contained in:
parent
8f685dea00
commit
02bcdf87cc
2
bbs.h
2
bbs.h
@ -221,7 +221,7 @@ extern void free_message_headers(struct msg_headers *msghs);
|
|||||||
extern struct msg_headers *read_message_headers(int msgconf, int msgarea, struct user_record *user);
|
extern struct msg_headers *read_message_headers(int msgconf, int msgarea, struct user_record *user);
|
||||||
extern void mail_scan(struct user_record *user);
|
extern void mail_scan(struct user_record *user);
|
||||||
extern int mail_menu(struct user_record *user);
|
extern int mail_menu(struct user_record *user);
|
||||||
extern char *editor(struct user_record *user, char *quote, char *from, int email);
|
extern char *editor(struct user_record *user, char *quote, int qlen, char *from, int email);
|
||||||
extern char *external_editor(struct user_record *user, char *to, char *from, char *quote, int qlen, char *qfrom, char *subject, int email);
|
extern char *external_editor(struct user_record *user, char *to, char *from, char *quote, int qlen, char *qfrom, char *subject, int email);
|
||||||
extern int msg_is_to(struct user_record *user, char *addressed_to, char *address, int type, int rn, int msgconf);
|
extern int msg_is_to(struct user_record *user, char *addressed_to, char *address, int type, int rn, int msgconf);
|
||||||
extern int msg_is_from(struct user_record *user, char *addressed_from, char *address, int type, int rn, int msgconf);
|
extern int msg_is_from(struct user_record *user, char *addressed_from, char *address, int type, int rn, int msgconf);
|
||||||
|
@ -547,10 +547,10 @@ char *external_editor(struct user_record *user, char *to, char *from, char *quot
|
|||||||
return body2;
|
return body2;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return editor(user, quote, qfrom, email);
|
return editor(user, quote, qlen, qfrom, email);
|
||||||
}
|
}
|
||||||
|
|
||||||
char *editor(struct user_record *user, char *quote, char *from, int email) {
|
char *editor(struct user_record *user, char *quote, int quotelen, char *from, int email) {
|
||||||
int lines = 0;
|
int lines = 0;
|
||||||
char buffer[256];
|
char buffer[256];
|
||||||
char linebuffer[80];
|
char linebuffer[80];
|
||||||
@ -571,7 +571,7 @@ char *editor(struct user_record *user, char *quote, char *from, int email) {
|
|||||||
memset(next_line_buffer, 0, 80);
|
memset(next_line_buffer, 0, 80);
|
||||||
|
|
||||||
if (quote != NULL) {
|
if (quote != NULL) {
|
||||||
for (i=0;i<strlen(quote);i++) {
|
for (i=0;i<quotelen;i++) {
|
||||||
if (quote[i] == '\r' || lineat == 67) {
|
if (quote[i] == '\r' || lineat == 67) {
|
||||||
if (quotelines == 0) {
|
if (quotelines == 0) {
|
||||||
quotecontent = (char **)malloc(sizeof(char *));
|
quotecontent = (char **)malloc(sizeof(char *));
|
||||||
|
Reference in New Issue
Block a user