When clicking on a contact's email address to send
authorArt Cancro <ajc@citadel.org>
Wed, 27 Feb 2008 21:45:37 +0000 (21:45 +0000)
committerArt Cancro <ajc@citadel.org>
Wed, 27 Feb 2008 21:45:37 +0000 (21:45 +0000)
them mail, put the display name inside quotes.  This escapes any commas
which may be present.  Resolves bug 271.

webcit/messages.c

index f22d0f16d9ab0b99a317de6bc42a08d72b526eee..4a27453f665bcef2ff4aa8e6dc5b7a1c0951e39e 100644 (file)
@@ -550,10 +550,12 @@ void display_parsed_vcard(struct vCard *v, int full) {
                                        "<a href=\"display_enter"
                                        "?force_room=_MAIL_?recp=");
 
+                               len = strlen(mailto);
+                               urlesc(&mailto[len], SIZ - len, "\"");
                                len = strlen(mailto);
                                urlesc(&mailto[len], SIZ - len,  fullname);
                                len = strlen(mailto);
-                               urlesc(&mailto[len], SIZ - len, " <");
+                               urlesc(&mailto[len], SIZ - len, "\" <");
                                len = strlen(mailto);
                                urlesc(&mailto[len], SIZ - len, thisvalue);
                                len = strlen(mailto);