From nobody Thu Feb 20 02:49:38 2025 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4YyyQq0fNXz5p5Ff; Thu, 20 Feb 2025 02:49:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4YyyQp6swHz45YC; Thu, 20 Feb 2025 02:49:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1740019779; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LNdF30+apqnshIXnbOuWcuThHLRLCeg3Pb2rUG6+NXU=; b=hiavJJFYl4U1IirKfZlJx+TjwkqewHpyo/stbPxVVLbdGfnJNUpP+mzXOL+nqXvGX8S3or dftOsO8tL0t67vQtXd7F+YJcfab/JEzpuzEBpNhRjNyMFck4VkhdKePdA+5rUXIytAvZKe IaY5ayiJBq2S9VJ+2t/PVqzvNnjGVdz+HumZxG47vbOBaxyBnvrofvMrLzTV9OmWyHhhib 3yQi3rgj4AbZto00jgDYvrcKnIZN3+3WZ+bVKVa5O7rbCnoYDqZ5+VrY5/duLi0Y3aB+gn 2ETUw1RsCRsowX5NAo1uSwVCYm8f+mwmdPiOJw1MDqJdX0RjMZWmRNA1rweIXw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1740019779; a=rsa-sha256; cv=none; b=fwjqGDYcMPllXWGSyI63glBvXzE4WQVIji+3dEBDvoiAWExUXXgcIYWrUKF2cvsrpGNTud 6pkWTtQC34hoIxUPKpBKjSsbpxNuxdEzQVqL8e1RUP4qx7NuYwmE8URQUSWBZcEDp9rcuY zOM87wLAt610kQK0VHg42L0ighjQG8AgtJQ4gsv00xiBfUEmXo8k7eLf1ec6N7IJh0PkPO XtyqVW5pHSVIgRZqxHDdmE+BpEH2g5Lk5OjLX4dWzXe0bysD4ep7lGQKC34VAmaAD7xx7q Eu0ld6rMnBsKPcK4fQiIdpHM4ahvP25tT2N4vaYuhTLRJ0JUuzwib88vzshxbA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1740019779; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LNdF30+apqnshIXnbOuWcuThHLRLCeg3Pb2rUG6+NXU=; b=iEaA6vPOWUGpW2+90ySRmuhWrFxQHIOGt0ubrGweqNjqLYHwC4wQMb6Wkq5ejs8aVRVwp6 3TlrQ69m8UytMpmTD7qp+8R7SW6H/OV5elDbSpD9EowcZwVOPLgVMtR7EcqUG4/5WM4zZa SNy6rSHZmimX0mRLsvoiYSAuEvue9phY/wej+2cBT6k4Mrf8KkZ7xmok498vKDF4+ElC39 nsgPhuhMhjOuPo4N46fSf3Kd6V3aows1tajy7OwLzputfPiBfUiOKvvycMGZoKyjjKs9TY vi69QtjjyZXBfX/kE63pslMiQtDpR9/dMJoN9il3DUfGOPN3Gkr7xShW0eWrGw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4YyyQp6LmdzYsv; Thu, 20 Feb 2025 02:49:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 51K2ncqr045434; Thu, 20 Feb 2025 02:49:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 51K2ncMD045431; Thu, 20 Feb 2025 02:49:38 GMT (envelope-from git) Date: Thu, 20 Feb 2025 02:49:38 GMT Message-Id: <202502200249.51K2ncMD045431@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: fb4102bc52a6 - stable/13 - vtfontcvt: Improve error message for unsupported DWIDTH List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: fb4102bc52a69e6736d69818460c01c253bd8753 Auto-Submitted: auto-generated The branch stable/13 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=fb4102bc52a69e6736d69818460c01c253bd8753 commit fb4102bc52a69e6736d69818460c01c253bd8753 Author: Ed Maste AuthorDate: 2025-01-20 20:04:20 +0000 Commit: Ed Maste CommitDate: 2025-02-20 02:49:24 +0000 vtfontcvt: Improve error message for unsupported DWIDTH vtfontcvt requires that all glyphs are 1x or 2x a common width, reporting for example "bitmap with unsupported DWIDTH 27 0 on line xxx" if the font is expected to be 32 pixels wide. Add the expected / permitted values to the error message to make the issue more clear - for the same example, "bitmap with unsupported DWIDTH 27 0 (not 32 or 64)". Reviewed by: ziaee Sponsored by: The FreeBSD Foundation (cherry picked from commit 3433daae0d20d55503084c4d17b8a3e685657ad2) (cherry picked from commit 036ce9b76e0ac5bb3a611a4b259a39e3158c25d4) --- usr.bin/vtfontcvt/vtfontcvt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.bin/vtfontcvt/vtfontcvt.c b/usr.bin/vtfontcvt/vtfontcvt.c index d68516dda360..508e298257a4 100644 --- a/usr.bin/vtfontcvt/vtfontcvt.c +++ b/usr.bin/vtfontcvt/vtfontcvt.c @@ -451,8 +451,8 @@ parse_bdf(FILE *fp, unsigned int map_idx) if (sscanf(ln + 7, "%d %d", &dwidth, &dwy) != 2) errx(1, "invalid DWIDTH at line %u", linenum); if (dwy != 0 || (dwidth != fbbw && dwidth * 2 != fbbw)) - errx(1, "bitmap with unsupported DWIDTH %d %d at line %u", - dwidth, dwy, linenum); + errx(1, "bitmap with unsupported DWIDTH %d %d (not %d or %d) at line %u", + dwidth, dwy, fbbw, 2 * fbbw, linenum); if (dwidth < fbbw) set_width(dwidth); }