aboutsummaryrefslogtreecommitdiffstats
path: root/audio/vorbis-tools/files/patch-share::iconvert.c
diff options
context:
space:
mode:
authornaddy <naddy@FreeBSD.org>2002-02-15 00:59:45 +0800
committernaddy <naddy@FreeBSD.org>2002-02-15 00:59:45 +0800
commit1d626a969bdc3d5bbfcfecb62d4c72f1aad6b2d1 (patch)
tree1f42d1627e1bbff4ee70d4d4e53c28d05de7bfbf /audio/vorbis-tools/files/patch-share::iconvert.c
parente48946c9a292286bbb1f8b4c3db5c686ce58f9f4 (diff)
downloadfreebsd-ports-gnome-1d626a969bdc3d5bbfcfecb62d4c72f1aad6b2d1.tar.gz
freebsd-ports-gnome-1d626a969bdc3d5bbfcfecb62d4c72f1aad6b2d1.tar.zst
freebsd-ports-gnome-1d626a969bdc3d5bbfcfecb62d4c72f1aad6b2d1.zip
Disable some asserts() that assume implementation characteristics
of glibc iconv().
Diffstat (limited to 'audio/vorbis-tools/files/patch-share::iconvert.c')
-rw-r--r--audio/vorbis-tools/files/patch-share::iconvert.c29
1 files changed, 29 insertions, 0 deletions
diff --git a/audio/vorbis-tools/files/patch-share::iconvert.c b/audio/vorbis-tools/files/patch-share::iconvert.c
new file mode 100644
index 000000000000..407ea9d47a91
--- /dev/null
+++ b/audio/vorbis-tools/files/patch-share::iconvert.c
@@ -0,0 +1,29 @@
+
+$FreeBSD$
+
+--- share/iconvert.c.orig Wed Dec 19 03:57:31 2001
++++ share/iconvert.c Thu Feb 14 16:52:41 2002
+@@ -105,10 +105,12 @@
+ obl = utflen;
+ for (;;) {
+ k = iconv(cd1, &ib, &ibl, &ob, &obl);
++#if 0 /* mistaken assumptions */
+ assert((!k && !ibl) ||
+ (k == (size_t)(-1) && errno == E2BIG && ibl && obl < 6) ||
+ (k == (size_t)(-1) &&
+ (errno == EILSEQ || errno == EINVAL) && ibl));
++#endif
+ if (!ibl)
+ break;
+ if (obl < 6) {
+@@ -216,8 +218,10 @@
+ }
+ }
+ k = iconv(cd2, 0, 0, &ob, &obl);
++#if 0
+ assert(!k);
+ assert(!obl);
++#endif
+ *ob = '\0';
+
+ free(utfbuf);