use my own APIS for headers, parameters and so on
[apps/madmutt.git] / hook.c
diff --git a/hook.c b/hook.c
index 836a882..e763f14 100644 (file)
--- a/hook.c
+++ b/hook.c
@@ -19,7 +19,7 @@
 
 #include "mutt.h"
 #include "mx.h"
-#include "mutt_crypt.h"
+#include <lib-crypt/crypt.h>
 #include "compress.h"
 
 #include "lib/rx.h"
@@ -33,7 +33,7 @@
 #define ERROR_STOP      0
 
 typedef struct hook {
-  unsigned long type;           /* hook type */
+  int type;                     /* hook type */
   rx_t rx;                      /* regular expression */
   char *command;                /* filename, command or pattern to execute */
   pattern_t *pattern;           /* used for fcc,save,send-hook */
@@ -301,7 +301,7 @@ void mutt_folder_hook (char *path)
   current_hook_type = 0;
 }
 
-char *mutt_find_hook (unsigned long type, const char *pat)
+char *mutt_find_hook (int type, const char *pat)
 {
   HOOK *tmp = Hooks;
 
@@ -313,7 +313,7 @@ char *mutt_find_hook (unsigned long type, const char *pat)
   return (NULL);
 }
 
-void mutt_message_hook (CONTEXT * ctx, HEADER * hdr, unsigned long type)
+void mutt_message_hook (CONTEXT * ctx, HEADER * hdr, int type)
 {
   BUFFER err, token;
   HOOK *hook;
@@ -440,7 +440,6 @@ char *mutt_crypt_hook (address_t * adr)
   return _mutt_string_hook (adr->mailbox, M_CRYPTHOOK);
 }
 
-#ifdef USE_SOCKET
 void mutt_account_hook (const char *url)
 {
   HOOK *hook;
@@ -471,4 +470,3 @@ void mutt_account_hook (const char *url)
 
   p_delete(&token.data);
 }
-#endif