Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 13 Jan 2008 08:32:47 +0100 (CET)
From:      peter.schuller@infidyne.com
To:        FreeBSD-gnats-submit@FreeBSD.org
Cc:        garga@FreeBSD.org
Subject:   ports/119619: [patch] net-im/jabber-pyicq broken with utf-8 decoding errors
Message-ID:  <20080113073247.D9ACD23C424@hyperion.scode.org>
Resent-Message-ID: <200801130740.m0D7e06q062094@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         119619
>Category:       ports
>Synopsis:       [patch] net-im/jabber-pyicq broken with utf-8 decoding errors
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Sun Jan 13 07:40:00 UTC 2008
>Closed-Date:
>Last-Modified:
>Originator:     peter.schuller@infidyne.com
>Release:        FreeBSD 6.2-RELEASE-p8 i386
>Organization:
>Environment:
System: FreeBSD hyperion.scode.org 6.2-RELEASE-p8 FreeBSD 6.2-RELEASE-p8 #0: Fri Oct 19 05:50:09 CEST 2007 scode@hyperion.scode.org:/usr/obj/usr/src/sys/GENERIC i386
>Description:
	After an upgrade to current versions of ports, ICQ presence code fails with:

	exceptions.UnicodeDecodeError: 'utf8' codec can't decode byte 0x97 in
	position 19: unexpected code byte

	There are several issues open that describe this upstream. This patch
	applies the change suggested here (and bumps PORTREVISION):

		http://code.google.com/p/pyicqt/issues/detail?id=79
>How-To-Repeat:
>Fix:
===> Generating patch
===> Viewing diff with more
diff -ruN --exclude=CVS /usr/ports/net-im/jabber-pyicq.orig/Makefile /usr/ports/net-im/jabber-pyicq/Makefile
--- /usr/ports/net-im/jabber-pyicq.orig/Makefile	2007-06-15 22:57:18.000000000 +0200
+++ /usr/ports/net-im/jabber-pyicq/Makefile	2008-01-13 08:25:44.801860827 +0100
@@ -6,6 +6,7 @@
 
 PORTNAME=	pyicq
 PORTVERSION=	0.8a
+PORTREVISION=	1
 CATEGORIES=	net-im
 MASTER_SITES=	http://www.blathersource.org/download.php/pyicq-t/
 PKGNAMEPREFIX=	jabber-
diff -ruN --exclude=CVS /usr/ports/net-im/jabber-pyicq.orig/files/patch-src_legacy_icqt.py /usr/ports/net-im/jabber-pyicq/files/patch-src_legacy_icqt.py
--- /usr/ports/net-im/jabber-pyicq.orig/files/patch-src_legacy_icqt.py	1970-01-01 01:00:00.000000000 +0100
+++ /usr/ports/net-im/jabber-pyicq/files/patch-src_legacy_icqt.py	2008-01-13 08:22:00.559630072 +0100
@@ -0,0 +1,12 @@
+--- src/legacy/icqt.py.orig	2008-01-09 04:58:42.000000000 +0100
++++ src/legacy/icqt.py	2008-01-13 08:06:51.411126927 +0100
+@@ -327,7 +327,8 @@
+ 					status = msg[0] + ": " + status
+ 
+ 			status = status.decode(charset, 'replace')
+-			LogEvent(INFO, self.session.jabberID, "Away (%s, %s) message %s" % (charset, msg[0], status))
++			utfmsg = unicode(msg[0], errors='replace')
++			LogEvent(INFO, self.session.jabberID, "Away (%s, %s) message %s" % (charset, utfmsg[0], status))
+ 
+ 		if status == "Away" or status=="I am currently away from the computer." or status=="I am away from my computer right now.":
+ 			status = ""


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20080113073247.D9ACD23C424>