Handle RFC822 'References:' field and Citadel W (Wefewences) field
[citadel.git] / citadel / msgbase.c
index 74bec403afb8848b716bcc4dfc9d01f210737f10..81ee81aa8e8c8e78b94324af31abdf17cb047ea7 100644 (file)
@@ -100,7 +100,7 @@ char *msgkeys[] = {
        "time",
        "subj",
        NULL,
-       NULL,
+       "wefw",
        NULL,
        "cccc",
        NULL
@@ -1689,6 +1689,20 @@ int CtdlOutputPreLoadedMsg(
                                                atol(mptr), DATESTRING_RFC822);
                                        cprintf("Date: %s%s", datestamp, nl);
                                }
+                               else if (i == 'W') {
+                                       cprintf("References: ");
+                                       k = num_tokens(mptr, '|');
+                                       for (i=0; i<k; ++i) {
+                                               extract_token(buf, mptr, i, '|', sizeof buf);
+                                               cprintf("<%s>", buf);
+                                               if (i == (k-1)) {
+                                                       cprintf("%s", nl);
+                                               }
+                                               else {
+                                                       cprintf(" ");
+                                               }
+                                       }
+                               }
                        }
                }
                if (subject_found == 0) {