+
+ /* Modern clients are using vNote format. Check for one... */
+
+ mime_parser(msg->cm_fields['M'],
+ NULL,
+ *notes_extract_vnote,
+ NULL, NULL,
+ &v, /* user data ptr - put the vnote here */
+ 0
+ );
+
+ if (v == NULL) return(0); /* no vNotes were found in this message */
+
+ /* Set the message EUID to the vNote UID */
+
+ if (v->uid) if (!IsEmptyStr(v->uid)) {
+ CtdlLogPrintf(9, "UID of vNote is: %s\n", v->uid);
+ if (msg->cm_fields['E'] != NULL) {
+ free(msg->cm_fields['E']);
+ }
+ msg->cm_fields['E'] = strdup(v->uid);
+ }
+
+ /* Set the message Subject to the vNote Summary */
+
+ if (v->summary) if (!IsEmptyStr(v->summary)) {
+ if (msg->cm_fields['U'] != NULL) {
+ free(msg->cm_fields['U']);
+ }
+ msg->cm_fields['U'] = strdup(v->summary);
+ if (strlen(msg->cm_fields['U']) > 72) {
+ strcpy(&msg->cm_fields['U'][68], "...");
+ }
+ }
+
+ vnote_free(v);