From owner-svn-src-head@freebsd.org Fri Jun 10 05:21:53 2016 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A914CB70682; Fri, 10 Jun 2016 05:21:53 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7B23C1A5D; Fri, 10 Jun 2016 05:21:53 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u5A5LqHE035073; Fri, 10 Jun 2016 05:21:52 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u5A5Lqa6035072; Fri, 10 Jun 2016 05:21:52 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201606100521.u5A5Lqa6035072@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Fri, 10 Jun 2016 05:21:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r301777 - head/lib/libc/stdio X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Jun 2016 05:21:53 -0000 Author: pfg Date: Fri Jun 10 05:21:52 2016 New Revision: 301777 URL: https://svnweb.freebsd.org/changeset/base/301777 Log: Fix regression from r301461. The fix to the __collate_range_cmp() ABI breakage missed some replacements in libc's vfscanf(). Replace them with __wcollate_range_cmp() which does what is expected. This was breaking applications like xterm and pidgin when using wide characters. Reported by: Vitalij Satanivskij Approved by: re Modified: head/lib/libc/stdio/vfscanf.c Modified: head/lib/libc/stdio/vfscanf.c ============================================================================== --- head/lib/libc/stdio/vfscanf.c Fri Jun 10 04:04:55 2016 (r301776) +++ head/lib/libc/stdio/vfscanf.c Fri Jun 10 05:21:52 2016 (r301777) @@ -873,7 +873,7 @@ doswitch: n = *fmt; if (n == ']' || (table->__collate_load_error ? n < c : - __collate_range_cmp (table, n, c) < 0 + __wcollate_range_cmp(table, n, c) < 0 ) ) { c = '-'; @@ -887,8 +887,8 @@ doswitch: } while (c < n); } else { for (i = 0; i < 256; i ++) - if ( __collate_range_cmp (table, c, i) < 0 - && __collate_range_cmp (table, i, n) <= 0 + if (__wcollate_range_cmp(table, c, i) < 0 && + __wcollate_range_cmp(table, i, n) <= 0 ) tab[i] = v; }