From nobody Wed Feb 15 19:39:13 2023 X-Original-To: freebsd-arm@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 4PH7gh66tLz3rFh9 for ; Wed, 15 Feb 2023 19:39:28 +0000 (UTC) (envelope-from marklmi@yahoo.com) Received: from sonic309-21.consmr.mail.gq1.yahoo.com (sonic309-21.consmr.mail.gq1.yahoo.com [98.137.65.147]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4PH7gh2q6tz4Jlx for ; Wed, 15 Feb 2023 19:39:28 +0000 (UTC) (envelope-from marklmi@yahoo.com) Authentication-Results: mx1.freebsd.org; none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1676489966; bh=+YrjK5jFkLVLjJV2/gx2NamGSBQMvUpicY++SV7yfMo=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From:Subject:Reply-To; b=hlsIsa/ix4FD49dHjMI49JpPAmOTv9H5jmhCjIi28e4/L/ahgeC6NiOd1299nt1Mr/Ze331FYm6ZgyCm/4jS+w4WadMkfYbqg062q8RuWe989S4u+vJea7FsxgksNE/aWytld3HUOFIzRMj55HFcDQSwBqvPd7P5HF1uB771o5vjjVMvI0mfTznqJri6owmNeXVxJYI4CH8wOoRqNTFG7mAR1yi+jQVm0XgmM3D3ZpU13+M84hnskjMV8RBCDSXoc92m4Z0GMzCikWL9dyBnjamenp4RexxiBNZ12UPaEfPUzcfcM4WOSwk65ner4G6m4lrtGikNAeI2d39/hUJh7Q== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1676489966; bh=LHy1rzKMpvpXFXUgP2O3QV2boFeGst/+K6p7My9+C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pqG1hH6qzM4xNvA2Iadp4fk0JOLR5W88U7.MgAlwDG7gKIiwEpw7FtuSRtD ipBXAx2z6F1qJBrg8h96k3dbHpKF.G4zE0IhALOHgT6jZwMufC4T1.uHuFKcnaiUtnYoKsDWbZBf 7i_iQugYDArttQX1.Vl2cO7CYZtXcVzU0gz3XUh3sn96U2otGkYRve.a4s9b.4pza1OdgGSLbhSY gCFO0wF3sQKvSbTYTBmCdMPpOxtsDFF9DbJDLVHpOZEOTmTT70UqRLd0NV6rHhNYTLMyIWccvwMp V5ZRsl9hWvhN3TFSC2ChGJZ6al2y3u4Cf4Fk7g.qodtuKxSWzwwd.yhs.fiZ3q3e9aGQWZ2j9ZNp Jl5jaisrptmOsGaEqfkntHgucb0wuVy2owuvPiSnp0BBrgWO9GPXhXZjBQhkMtWidwYI_O_3FA7t aSst_taZd6Ba9aODjwBwlFidptVuXmhA.6KuPBv92bQoGDVmdyuOZT6KUX5yIE5Gu73SCUJKNLFr xzCtuk77.DZY7iJZlhE8kACp96oRyemIugZx33YftVmRUerSa0n7co9wXOPgiHzYzlOfBOSbmroc - X-Sonic-MF: Received: from sonic.gate.mail.ne1.yahoo.com by sonic309.consmr.mail.gq1.yahoo.com with HTTP; Wed, 15 Feb 2023 19:39:26 +0000 Received: by hermes--production-gq1-655ddccc9-j6kw5 (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID e43f6812d050da1e2a089eab771621a2; Wed, 15 Feb 2023 19:39:24 +0000 (UTC) Content-Type: text/plain; charset=us-ascii List-Id: Porting FreeBSD to ARM processors List-Archive: https://lists.freebsd.org/archives/freebsd-arm List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-arm@freebsd.org Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3731.300.101.1.3\)) Subject: Re: fsck segfaults on rpi3 running 13-stable (and on 14-CURRENT analyzing the same file system that resulted from the 13-STABLE crash) From: Mark Millard In-Reply-To: <20230215190856.GA34665@www.zefox.net> Date: Wed, 15 Feb 2023 11:39:13 -0800 Cc: freebsd-arm@freebsd.org Content-Transfer-Encoding: quoted-printable Message-Id: References: <20230212195324.GB21535@www.zefox.net> <03840D0B-13D4-4F22-BDAF-2887A4D78BED@yahoo.com> <20230213232519.GD95670@funkthat.com> <20230214161415.GA28276@www.zefox.net> <20230214183827.GG95670@funkthat.com> <20230214210601.GA28959@www.zefox.net> <20230214232746.GI95670@funkthat.com> <20230215154424.GA34278@www.zefox.net> <20230215190856.GA34665@www.zefox.net> To: bob prohaska X-Mailer: Apple Mail (2.3731.300.101.1.3) X-Rspamd-Queue-Id: 4PH7gh2q6tz4Jlx X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:36647, ipnet:98.137.64.0/20, country:US] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-ThisMailContainsUnwantedMimeParts: N On Feb 15, 2023, at 11:08, bob prohaska wrote: > On Wed, Feb 15, 2023 at 09:40:51AM -0800, Mark Millard wrote: >>=20 >> Looking in my /usr/main-src/sbin/fsck_ffs/inode.c >> I see that the original file has a leading tab >> instead of spaces. >>=20 >> The following mostly ignores the 1st column that >> should have a space, -, or + in the diff output for >> the file-content lines. It is mostly about the text >> after the first column. >>=20 >> So, if you have spaces instead after the first column >> for the lines that start with a space, those lines >> will not match, leading to a rejection for the >> context matching done by patch. >=20 > Replacing spaces with tabs allowed patch to find the=20 > location, but it still fails with=20 > patch: **** malformed patch at line 5: printf("SIZE=3D%ju ", = (uintmax_t)DIP(dp, di_size)); My guess is that when you made the adjustment to have the tabs, the leading space was also removed on this line. The first column is not part of the original text but is instead a directive to the tool. The missing space would be that directive and it needs to be there. So: printf("SIZE=3D%ju ", (uintmax_t)DIP(dp, di_size)); The space indicates to use the reset of the line just for context identification. Of course, since I've no access the file to check my hypothesis, it is just a guess. > Editing by hand looks like a good way to drive myself crazy 8-) >=20 > I take it the goal is to find the lines > printf("SIZE=3D%ju ", (uintmax_t)DIP(dp, di_size)); > t =3D DIP(dp, di_mtime); > p =3D ctime(&t); > delete the line=20 > printf("MTIME=3D%12.12s %4.4s ", &p[4], &p[20]); Yes. (I ignored whitespace details here: not preserved in the E-mail result as I see it.) > and add the four lines > if (p =3D=3D NULL) > printf("MTIME=3Dinvalid "); > else > printf("MTIME=3D%12.12s %4.4s ", &p[4], &p[20]); =20 Yes. (I ignored whitespace details here too.) > Do I at least correctly understand the intent of the patch? >=20 Yes. =3D=3D=3D Mark Millard marklmi at yahoo.com