From nobody Thu Jan 23 08:59:27 2025 X-Original-To: pkg@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 4YdvyQ6nxzz5lrrL for ; Thu, 23 Jan 2025 08:59:26 +0000 (UTC) (envelope-from bugzilla-noreply@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 4YdvyQ62VGz3ml3 for ; Thu, 23 Jan 2025 08:59:26 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1737622766; 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: in-reply-to:in-reply-to:references:references; bh=gc8M1r+ciaM3dJEeU58y05Qwi4APfJ2yDuI0fQ42tqo=; b=CzAo4cMU42yPnyJ1Ux3jhAyEuhvcH0cLWKcX0Y7FToH+6RpVbS00Q4EmtcJ0KyqJhWbXj8 inYTrNgat3SkNoDervMexzMRIm/wIMjylFJH6jdyJsyoAXi6+fps972cD2oM1iZ9PNUPAN sA4SsKmI7teW9qTCgI1iE+5vmY78t4RO3S4c21t4t9CVlYltSCaFAptKrs33U3G3FByqIt TsZbVitiJWg+iW1YT4nf1YevYBcwIveLZvc6J3z4+GUXbscKL4BESMOXWyELV5o2dt7WnN JGaMRMcVOLx5GANvtMKBPOEwDhtecvp0d55ffrlgTsCGlef3SjbUao9yW1uRFw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1737622766; 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: in-reply-to:in-reply-to:references:references; bh=gc8M1r+ciaM3dJEeU58y05Qwi4APfJ2yDuI0fQ42tqo=; b=YomC4MKWE+qpBNGslhXdc2ySWbtBt60zM3X+i8iBm0KhtCISuZFr0RWDW0Nc3GFh+7FrCS 95pG3yO+Vy/x2ZRON2YyaX3f3tIsiQeqR/d9a9VBOCalUKnb89TA8tULkpR5HxogLE6THc S7wfIqUnVYclLkIxnh/RgEUkDrqmEf91aUmj7dp6BwtgzUxhbW8edNXpKVkIGR6jm9BNp1 WC0HxtTarofXT5at+uf98Sf2D6/3pB92Z+Pm7/M3NDDBxbrB+FKCvid0hPMr6WPETNxSvS fYbGCrdhlEsXWzVpYtpCBCgcgAyoOBGK/b4Fe8zJtYgWfX3Mt+ePKfY3AbCb+w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1737622766; a=rsa-sha256; cv=none; b=iL6q7t/mkhMOl3eK8g3t/HC0Fss8xNal3IO1z8N8Sx6ZzheXp4Ic4UseMJKmW20DGaE2Au snSOyYPgi/Ey0ULw+GUBZVLN7IqxU+QBcAUbyJoXhrfdPoQDKk8r61N+zS4t31PGwvXuz8 HVsnAw9Kz7TdNfPKva8mKQlTYaotN3ML9pVDPqa6KP721VmeNcIkq7RtWjSmScWT4UgDjx HcYODkz0dp+oCDOS4N9blafKincsKuMA7MyZn1O13qLqiLEVGaUxbr9Q4eLuZ2vG1nqVWb uSUMqbde0MQIXEu2hmMQ+PLYO3W9SmWu/DX6VviwE93LQv2PAj4WsSFTu0guOg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (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 4YdvyQ5NfMzWsl for ; Thu, 23 Jan 2025 08:59:26 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 50N8xQao031061 for ; Thu, 23 Jan 2025 08:59:26 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 50N8xQkN031060 for pkg@FreeBSD.org; Thu, 23 Jan 2025 08:59:26 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: pkg@FreeBSD.org Subject: [Bug 284276] ports-mgmt/pkg: 'version' command often segfaults when used with -o option after upgrading to pkg-2.0.0 Date: Thu, 23 Jan 2025 08:59:27 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Ports & Packages X-Bugzilla-Component: Individual Port(s) X-Bugzilla-Version: Latest X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: discipline@tiscali.it X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: pkg@FreeBSD.org X-Bugzilla-Flags: maintainer-feedback? X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="UTF-8" X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Binary package management and package tools discussion List-Archive: https://lists.freebsd.org/archives/freebsd-pkg List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-pkg@FreeBSD.org MIME-Version: 1.0 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D284276 --- Comment #2 from Ale --- I noticed that this is happening with both /usr/sbin/pkg and /usr/local/sbin/pkg,=20 $ ls -latr /usr/local/sbin/pkg /usr/sbin/pkg=20 -r-xr-xr-x 1 root wheel 35880 Dec 14 12:51 /usr/sbin/pkg -rwxr-xr-x 1 root wheel 4229024 Jan 23 07:01 /usr/local/sbin/pkg $ /usr/sbin/pkg version -o -n linux-quake4 Child process pid=3D59742 terminated abnormally: Segmentation fault $ /usr/local/sbin/pkg version -o -n linux-quake4 Child process pid=3D59831 terminated abnormally: Segmentation fault $ uname -Kvm FreeBSD 14.2-STABLE 9bc9cf4a2 STARLESS amd64 1402501 but I'm pretty sure it started crashing since yesterday, after upgrading ports-mgmt/pkg (in my case pkg is an alias for the latter). I tried rebuilding the port WITH_DEBUG and... # ./work/stage/usr/local/sbin/pkg version -o -n linux-quake4 Child process pid=3D59543 terminated abnormally: Segmentation fault # lldb ./work/stage/usr/local/sbin/pkg --core /usr/ports/pkg.core (lldb) target create "./work/stage/usr/local/sbin/pkg" --core "/usr/ports/pkg.core" Core file '/usr/ports/pkg.core' (x86_64) was loaded. (lldb) bt * thread #1, name =3D 'pkg', stop reason =3D signal SIGSEGV * frame #0: 0x000000000058d504 pkg`format_comment(buf=3D0x000026d13d24c48= 0, data=3D0x000000000000003e, p=3D0x000026d13d22a400) at pkg_printf.c:1617:31 frame #1: 0x000000000058b578 pkg`process_format_main(buf=3D0x000026d13d24c480, p=3D0x000026d13d22a400, fstart=3D"", fend=3D"", data=3D0x000000000000003e) at pkg_printf.c:2900:6 frame #2: 0x000000000058ac28 pkg`pkg_xstring_vprintf(buf=3D0x000026d13d24c480, format=3D"", ap=3D0x00000008210f2270) at pkg_printf.c:3191:8 frame #3: 0x000000000058a9f1 pkg`pkg_vprintf(format=3D"", ap=3D0x00000008210f2270) at pkg_printf.c:2942:9 frame #4: 0x000000000058a98b pkg`pkg_printf(format=3D"") at pkg_printf.c:2921:10 frame #5: 0x000000000032098c pkg`print_version(pkg=3D0x000026d13d316000, source=3D"", ver=3D"1.4.2_1,1", limchar=3D'-', opt=3D9218) at version.c:117= :3 frame #6: 0x0000000000320346 pkg`do_source_ports(opt=3D9218, limchar=3D= '-', pattern=3D0x0000000000000000, match=3DMATCH_ALL, matchorigin=3D0x0000000000= 000000, matchname=3D"linux-quake4", portsdir=3D"/usr/ports") at version.c:773:3 frame #7: 0x000000000031f63f pkg`exec_version(argc=3D0, argv=3D0x00000008210f3240) at version.c:1008:11 frame #8: 0x0000000000310591 pkg`main(argc=3D4, argv=3D0x00000008210f32= 20) at main.c:809:9 frame #9: 0x00000008262191c4 libc.so.7`__libc_start1(argc=3D5, argv=3D0x00000008210f3218, env=3D0x00000008210f3248, cleanup=3D, mainX=3D(pkg`main at main.c:489)) at libc_start1.c:157:7 frame #10: 0x0000000000301f80 pkg`_start at crt1_s.S:83 (lldb) f 0 frame #0: 0x000000000058d504 pkg`format_comment(buf=3D0x000026d13d24c480, data=3D0x000000000000003e, p=3D0x000026d13d22a400) at pkg_printf.c:1617:31 1614 { 1615 const struct pkg *pkg =3D data; 1616=20 -> 1617 return (string_val(buf, pkg->comment, p)); 1618 } 1619=20 1620 /* (lldb) p *buf (xstring) { buf =3D 0x000026d13d208248 "" size =3D 0 fp =3D 0x000000082638a178 } (lldb) p *p (percent_esc) { flags =3D 0 width =3D 0 trailer_status =3D 0 item_fmt =3D 0x000026d13d252780 sep_fmt =3D 0x000026d13d2527c0 fmt_code =3D PP_PKG_COMMENT } (lldb) frame var *pkg (const pkg) *pkg =3D { direct =3D locked =3D automatic =3D vital =3D id =3D scripts =3D { [0] =3D [1] =3D [2] =3D [3] =3D [4] =3D [5] =3D [6] =3D [7] =3D [8] =3D } lua_scripts =3D { [0] =3D { head =3D tail =3D length =3D } [1] =3D { head =3D tail =3D length =3D } [2] =3D { head =3D tail =3D length =3D } [3] =3D { head =3D tail =3D length =3D } [4] =3D { head =3D tail =3D length =3D } } name =3D origin =3D version =3D old_version =3D maintainer =3D www =3D altabi =3D abi =3D uid =3D digest =3D old_digest =3D message =3D { head =3D tail =3D length =3D } prefix =3D oprefix =3D comment =3D desc =3D sum =3D repopath =3D reponame =3D repourl =3D reason =3D dep_formula =3D licenselogic =3D pkgsize =3D flatsize =3D old_flatsize =3D timestamp =3D depshash =3D depends =3D rdepshash =3D rdepends =3D categories =3D { head =3D tail =3D length =3D } licenses =3D { head =3D tail =3D length =3D } filehash =3D files =3D dirhash =3D dirs =3D optionshash =3D options =3D users =3D { head =3D tail =3D length =3D } groups =3D { head =3D tail =3D length =3D } shlibs_required =3D { head =3D tail =3D length =3D } shlibs_provided =3D { head =3D tail =3D length =3D } conflictshash =3D conflicts =3D provides =3D { head =3D tail =3D length =3D } requires =3D { head =3D tail =3D length =3D } config_files_hash =3D config_files =3D annotations =3D { head =3D tail =3D length =3D } flags =3D rootfd =3D rootpath =3D "" dir_to_del =3D { head =3D tail =3D length =3D } type =3D repo =3D } Let me know if i can do any other test that might help. --=20 You are receiving this mail because: You are the assignee for the bug.=