pkgsrc-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
pkg/35825: devel/libosip2-2.2.2 has 64-bit unclean bug [with patch]
>Number: 35825
>Category: pkg
>Synopsis: devel/libosip2-2.2.2 has 64-bit unclean bug [with patch]
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: pkg-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sat Feb 24 11:50:00 +0000 2007
>Originator: Rhialto
>Release: NetBSD 3.0
>Organization:
>Environment:
System: NetBSD radl.falu.nl 3.0 NetBSD 3.0 (Radls Doordringend Onjuiste
Akkoord) #1: Thu Sep 14 02:39:33 CEST 2006
root%radl.falu.nl@localhost:/usr/src/sys/arch/amd64/compile/RADL amd64
Architecture: x86_64
Machine: amd64
>Description:
There is a hash function that returns "unsigned long" but its
return values are compared with 32-bit values.
I have reported the bug upstream, but the next versions up to
at least 3.0.1 do contain the problem.
>How-To-Repeat:
Try to use wip/siproxd (which uses this library) on an amd64,
and be surprised that it complains about missing header fields
(which are retrieved via hashing).
>Fix:
Add this patch file:
--- src/osipparser2/osip_port.c.orig 2006-12-20 21:11:55.000000000 +0100
+++ src/osipparser2/osip_port.c 2006-12-20 21:09:30.000000000 +0100
@@ -1091,7 +1091,7 @@
while (c = *str++)
hash = ((hash << 5) + hash) + c;
- return hash;
+ return hash & 0xFFFFFFFFu;
}
/* ---For better performance---
-Olaf.
--
___ Olaf 'Rhialto' Seibert -- You author it, and I'll reader it.
\X/ rhialto/at/xs4all.nl -- Cetero censeo "authored" delendum esse.
Home |
Main Index |
Thread Index |
Old Index