Rename hash_lookup() in src/c-client/misc.c to unusual name.
This hash_lookup() is internal function of imap but conflict with other package (converters/php-recode) and cause php binary to crash. Bump PKGREVISION.
This commit is contained in:
parent
6ea4168fbf
commit
b68b6a96c6
5 changed files with 81 additions and 3 deletions
|
@ -1,4 +1,4 @@
|
|||
# $NetBSD: Makefile,v 1.143 2016/03/05 11:27:50 jperkin Exp $
|
||||
# $NetBSD: Makefile,v 1.144 2017/06/02 05:35:21 taca Exp $
|
||||
#
|
||||
# ATTENTION:
|
||||
# The Kerberos support in this software is known to be problematic. If you
|
||||
|
@ -11,7 +11,7 @@
|
|||
|
||||
DISTNAME= imap-2007f
|
||||
PKGNAME= ${DISTNAME:S/-/-uw-/}
|
||||
PKGREVISION= 3
|
||||
PKGREVISION= 4
|
||||
CATEGORIES= mail
|
||||
MASTER_SITES= ftp://ftp.cac.washington.edu/imap/
|
||||
EXTRACT_SUFX= .tar.Z
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
$NetBSD: distinfo,v 1.44 2015/11/03 23:27:07 agc Exp $
|
||||
$NetBSD: distinfo,v 1.45 2017/06/02 05:35:21 taca Exp $
|
||||
|
||||
SHA1 (imap-2007f.tar.Z) = 1c9935e5a261baec85dadcbc0c514b66fa3ce0a5
|
||||
RMD160 (imap-2007f.tar.Z) = 14f40284e9e164c0ed7677f1e5d8e3309c7c58c1
|
||||
|
@ -36,4 +36,7 @@ SHA1 (patch-be) = 73afbc9f3c65d3adce37a3f1ee7f55e0ec665a54
|
|||
SHA1 (patch-bf) = 63c582e88bd6286295d5d9639bafec355278d537
|
||||
SHA1 (patch-bg) = c95483ed73d7c6015df99967c0509cf0ea67d28f
|
||||
SHA1 (patch-bh) = c43dc5df9fb61ea44b5195fc15c697e5f540dfae
|
||||
SHA1 (patch-src_c-client_mail.c) = fca90d3a5a8770b8728bdef6aec2623d16c12b6d
|
||||
SHA1 (patch-src_c-client_misc.c) = d22ca95fb333b5234c66440faf5d6e30a148bad1
|
||||
SHA1 (patch-src_c-client_misc.h) = 5cf51d186b04ebb45c79b8042bbdcb01716dd2ce
|
||||
SHA1 (patch-src_mlock_Makefile) = 6bf652f597ad21dffa44e01d6cb89525eeaf7fc9
|
||||
|
|
43
mail/imap-uw/patches/patch-src_c-client_mail.c
Normal file
43
mail/imap-uw/patches/patch-src_c-client_mail.c
Normal file
|
@ -0,0 +1,43 @@
|
|||
$NetBSD: patch-src_c-client_mail.c,v 1.1 2017/06/02 05:35:21 taca Exp $
|
||||
|
||||
Rename hash_lookup() to unusual name to avoid conflict to other
|
||||
shared libraries. It should be internal function of libc-client.
|
||||
|
||||
--- src/c-client/mail.c.orig 2011-07-23 00:20:18.000000000 +0000
|
||||
+++ src/c-client/mail.c
|
||||
@@ -4938,7 +4938,7 @@ THREADNODE *mail_thread_references (MAIL
|
||||
if (s->unique && (s->unique != s->message_id))
|
||||
fs_give ((void **) &s->unique);
|
||||
s->unique = s->message_id ? /* don't permit Message ID duplicates */
|
||||
- (hash_lookup (ht,s->message_id) ? cpystr (tmp) : s->message_id) :
|
||||
+ (hash_lookup_ (ht,s->message_id) ? cpystr (tmp) : s->message_id) :
|
||||
(s->message_id = cpystr (tmp));
|
||||
/* add unique string to hash table */
|
||||
hash_add (ht,s->unique,s,THREADLINKS);
|
||||
@@ -4960,7 +4960,7 @@ THREADNODE *mail_thread_references (MAIL
|
||||
}
|
||||
else con = NIL; /* else message has no ancestors */
|
||||
/* Step 1B */
|
||||
- if ((prc = PARENT ((nxc = hash_lookup (ht,s->unique)))) &&
|
||||
+ if ((prc = PARENT ((nxc = hash_lookup_ (ht,s->unique)))) &&
|
||||
(prc != con)) { /* break links if have a different parent */
|
||||
SETPARENT (nxc,NIL); /* easy if direct child */
|
||||
if (nxc == CHILD (prc)) SETCHILD (prc,SIBLING (nxc));
|
||||
@@ -5022,7 +5022,7 @@ THREADNODE *mail_thread_references (MAIL
|
||||
for (cur = root; cur; cur = cur->branch)
|
||||
if ((t = (nxt = (cur->sc ? cur : cur->next))->sc->subject) && *t) {
|
||||
/* add new subject to hash table */
|
||||
- if (!(sub = hash_lookup (ht,t))) hash_add (ht,t,cur,0);
|
||||
+ if (!(sub = hash_lookup_ (ht,t))) hash_add (ht,t,cur,0);
|
||||
/* if one in table not dummy and */
|
||||
else if ((s = (lst = (THREADNODE *) sub[0])->sc) &&
|
||||
/* current dummy, or not re/fwd and table is */
|
||||
@@ -5034,7 +5034,7 @@ THREADNODE *mail_thread_references (MAIL
|
||||
for (cur = root, sis = NIL; cur; cur = msg) {
|
||||
/* do nothing if current message or no sub */
|
||||
if (!(t = (cur->sc ? cur : cur->next)->sc->subject) || !*t ||
|
||||
- ((lst = (THREADNODE *) (sub = hash_lookup (ht,t))[0]) == cur))
|
||||
+ ((lst = (THREADNODE *) (sub = hash_lookup_ (ht,t))[0]) == cur))
|
||||
msg = (sis = cur)->branch;
|
||||
else if (!lst->sc) { /* is message in the table a dummy? */
|
||||
/* find youngest daughter of msg in table */
|
16
mail/imap-uw/patches/patch-src_c-client_misc.c
Normal file
16
mail/imap-uw/patches/patch-src_c-client_misc.c
Normal file
|
@ -0,0 +1,16 @@
|
|||
$NetBSD: patch-src_c-client_misc.c,v 1.1 2017/06/02 05:35:21 taca Exp $
|
||||
|
||||
Rename hash_lookup() to unusual name to avoid conflict to other
|
||||
shared libraries. It should be internal function of libc-client.
|
||||
|
||||
--- src/c-client/misc.c.orig 2011-07-23 00:20:18.000000000 +0000
|
||||
+++ src/c-client/misc.c
|
||||
@@ -343,7 +343,7 @@ unsigned long hash_index (HASHTAB *hasht
|
||||
* Returns: associated data
|
||||
*/
|
||||
|
||||
-void **hash_lookup (HASHTAB *hashtab,char *key)
|
||||
+void **hash_lookup_ (HASHTAB *hashtab,char *key)
|
||||
{
|
||||
HASHENT *ret;
|
||||
for (ret = hashtab->table[hash_index (hashtab,key)]; ret; ret = ret->next)
|
16
mail/imap-uw/patches/patch-src_c-client_misc.h
Normal file
16
mail/imap-uw/patches/patch-src_c-client_misc.h
Normal file
|
@ -0,0 +1,16 @@
|
|||
$NetBSD: patch-src_c-client_misc.h,v 1.1 2017/06/02 05:35:21 taca Exp $
|
||||
|
||||
Rename hash_lookup() to unusual name to avoid conflict to other
|
||||
shared libraries. It should be internal function of libc-client.
|
||||
|
||||
--- src/c-client/misc.h.orig 2011-07-23 00:20:18.000000000 +0000
|
||||
+++ src/c-client/misc.h
|
||||
@@ -100,7 +100,7 @@ HASHTAB *hash_create (size_t size);
|
||||
void hash_destroy (HASHTAB **hashtab);
|
||||
void hash_reset (HASHTAB *hashtab);
|
||||
unsigned long hash_index (HASHTAB *hashtab,char *key);
|
||||
-void **hash_lookup (HASHTAB *hashtab,char *key);
|
||||
+void **hash_lookup_ (HASHTAB *hashtab,char *key);
|
||||
HASHENT *hash_add (HASHTAB *hashtab,char *key,void *data,long extra);
|
||||
void **hash_lookup_and_add (HASHTAB *hashtab,char *key,void *data,long extra);
|
||||
unsigned char hex2byte (unsigned char c1,unsigned char c2);
|
Loading…
Reference in a new issue