Skip to content

Commit

Permalink
Pullup ticket 2046 - requested by obache
Browse files Browse the repository at this point in the history
compatibility fix for cyrus-imapd

Revisions pulled up:
- pkgsrc/mail/cyrus-imapd/Makefile			1.70
- pkgsrc/mail/cyrus-imapd/distinfo			1.27
- pkgsrc/mail/cyrus-imapd/patches/patch-al		1.3

   Module Name:		pkgsrc
   Committed By:	obache
   Date:		Fri Mar  9 14:46:08 UTC 2007

   Modified Files:
   	pkgsrc/mail/cyrus-imapd: Makefile distinfo
   	pkgsrc/mail/cyrus-imapd/patches: patch-al

   Log Message:
   compatibility fix for SASL 2.1.22.
   Taken from:
   https://bugzilla.andrew.cmu.edu/cgi-bin/cvsweb.cgi/src/cyrus/imtest/imtest.c.diff?r1=1.107&r2=1.108

   Bump PKGREVISION.

   Reported by Jukka Salmi in PR 35959.
  • Loading branch information
salo committed Mar 9, 2007
1 parent b1c4591 commit b2d8a09
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 11 deletions.
4 changes: 2 additions & 2 deletions mail/cyrus-imapd/Makefile
@@ -1,7 +1,7 @@
# $NetBSD: Makefile,v 1.69 2006/12/01 13:36:59 joerg Exp $
# $NetBSD: Makefile,v 1.69.2.1 2007/03/09 15:26:59 salo Exp $

DISTNAME= cyrus-imapd-2.2.13
PKGREVISION= 2
PKGREVISION= 3
CATEGORIES= mail
MASTER_SITES= ftp://ftp.andrew.cmu.edu/pub/cyrus-mail/ \
ftp://ftp.andrew.cmu.edu/pub/cyrus-mail/OLD-VERSIONS/imap/
Expand Down
4 changes: 2 additions & 2 deletions mail/cyrus-imapd/distinfo
@@ -1,4 +1,4 @@
$NetBSD: distinfo,v 1.26 2006/12/01 13:36:59 joerg Exp $
$NetBSD: distinfo,v 1.26.2.1 2007/03/09 15:26:59 salo Exp $

SHA1 (cyrus-imapd-2.2.13.tar.gz) = ba84b67a1cae4c15d5a588d010764031167970c4
RMD160 (cyrus-imapd-2.2.13.tar.gz) = 7e8ac84b5ddd9f1206e71d5b659d07d8400f9ac2
Expand All @@ -9,7 +9,7 @@ SHA1 (patch-ac) = 48557e05ef0d82413da18dd46d9c4baf802a771d
SHA1 (patch-ad) = e99638a062b2695514c6859788eac3fd02cf5c1d
SHA1 (patch-ae) = b1865b68a8f798a3766e53e60e9e68099df9bd54
SHA1 (patch-af) = 2aaf1be5fcb102b047a57fe0a908b3e8f95037ea
SHA1 (patch-al) = 6fa8967eb97f7cfdb93de86a45aa90ab3a1bd129
SHA1 (patch-al) = d28a0e604f0ddcf22c6753be333216780558e05c
SHA1 (patch-am) = 0804e6fa6694ed820861b740ac1bead29b3eeb4b
SHA1 (patch-ap) = 95b987e83ddd53065f7ffe503d0f07694f9bcd6b
SHA1 (patch-aq) = 0d764585dc2af05964b03723c29ff127ebe3c25d
Expand Down
27 changes: 20 additions & 7 deletions mail/cyrus-imapd/patches/patch-al
@@ -1,7 +1,7 @@
$NetBSD: patch-al,v 1.2 2005/03/02 21:42:48 wiz Exp $
$NetBSD: patch-al,v 1.2.16.1 2007/03/09 15:26:59 salo Exp $

--- imtest/imtest.c.orig Wed Aug 4 15:03:18 2004
+++ imtest/imtest.c Sun Nov 28 15:12:44 2004
--- imtest/imtest.c.orig 2006-01-21 05:31:23.000000000 +0900
+++ imtest/imtest.c
@@ -47,7 +47,9 @@
#include <sys/time.h>
#include <sys/types.h>
Expand All @@ -12,14 +12,27 @@ $NetBSD: patch-al,v 1.2 2005/03/02 21:42:48 wiz Exp $
#include <sys/stat.h>
#include <fcntl.h>

@@ -71,6 +73,10 @@
#include <sys/file.h>
@@ -72,6 +74,10 @@
#include <netinet/in.h>
#include <netdb.h>
+
+#ifdef HAVE_SYS_PARAM_H
+#include <sys/param.h>
+#endif
+
#include <sasl/sasl.h>
#include <sasl/saslutil.h>

@@ -886,6 +892,12 @@ imt_stat getauthline(struct sasl_cmd_t *
}

if (*str != '\r') {
+ /* trim CRLF */
+ char *p = str + strlen(str) - 1;
+ if (p >= str && *p == '\n') *p-- = '\0';
+ if (p >= str && *p == '\r') *p-- = '\0';
+
+ /* alloc space for decoded response */
len = strlen(str) + 1;
*line = malloc(len);
if ((*line) == NULL) {

0 comments on commit b2d8a09

Please sign in to comment.