+++ /dev/null
-diff -ur dovecot-antispam-2.0/antispam-plugin.h dovecot-antispam-2.0-2.2/antispam-plugin.h
---- dovecot-antispam-2.0/antispam-plugin.h 2013-07-16 08:49:17.445971507 +0200
-+++ dovecot-antispam-2.0-2.2/antispam-plugin.h 2013-07-16 08:47:54.968547139 +0200
-@@ -287,6 +287,25 @@
- {
- return dict_init(uri, DICT_DATA_TYPE_STRING, username, NULL);
- }
-+#elif DOVECOT_IS_EQ(2, 2)
-+#define mempool_unref pool_unref
-+#define module_arg struct module *
-+#define ME(err) MAIL_ERROR_ ##err,
-+
-+static inline const char *const *
-+get_mail_headers(struct mail *mail, const char *hdr)
-+{
-+ const char *const *ret;
-+ if (mail_get_headers(mail, hdr, &ret))
-+ return NULL;
-+ return ret;
-+}
-+
-+static inline struct ostream *
-+o_stream_create_from_fd(int fd, pool_t pool ATTR_UNUSED)
-+{
-+ return o_stream_create_fd(fd, 0, TRUE);
-+}
- #else
- #error "Building against this dovecot version is not supported"
- #endif
-diff -ur dovecot-antispam-2.0/dovecot-version.c dovecot-antispam-2.0-2.2/dovecot-version.c
---- dovecot-antispam-2.0/dovecot-version.c 2013-07-16 08:49:17.445971507 +0200
-+++ dovecot-antispam-2.0-2.2/dovecot-version.c 2013-07-16 08:48:53.755753877 +0200
-@@ -55,7 +55,7 @@
- "DOVECOT_VCODE <= DOVECOT_VERSION_CODE(maj, min, 0)\n");
-
- /* Use the antispam-storage-2.0.c for dovecot 2.1 as well */
-- if (maj == 2 && min == 1)
-+ if (maj == 2 && (min == 1 || min == 2))
- min = 0;
-
- printf("#define ANTISPAM_STORAGE "
---- dovecot-antispam-2.0/antispam-plugin.c~ 2011-11-07 10:49:47.000000000 +0100
-+++ dovecot-antispam-2.0/antispam-plugin.c 2013-07-23 20:19:25.951626755 +0200
-@@ -392,4 +392,8 @@
- }
-
- /* put dovecot version we built against into plugin for checking */
-+#ifdef DOVECOT_ABI_VERSION
-+const char *PLUGIN_FUNCTION(version) = DOVECOT_ABI_VERSION;
-+#else
- const char *PLUGIN_FUNCTION(version) = PACKAGE_VERSION;
-+#endif