]> code.citadel.org Git - citadel.git/blobdiff - citadel/modules/autocompletion/serv_autocompletion.c
Accidentally merged the configdb branch into master. Reverting.
[citadel.git] / citadel / modules / autocompletion / serv_autocompletion.c
index f84020e7a12aa461ea0f4d917ee7d0670e80c902..00e190839bda557cdfeb6baafb410bf0f52e4245 100644 (file)
@@ -62,8 +62,8 @@ void hunt_for_autocomplete(long msgnum, char *search_string) {
        msg = CtdlFetchMessage(msgnum, 1);
        if (msg == NULL) return;
 
-       v = vcard_load(msg->cm_fields['M']);
-       CtdlFreeMessage(msg);
+       v = vcard_load(msg->cm_fields[eMesageText]);
+       CM_Free(msg);
 
        /*
         * Try to match from a friendly name (the "fn" field).  If there is