From nobody Tue Mar 08 00:33:30 2022 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 EFF2D19FF5DA; Tue, 8 Mar 2022 00:33:30 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4KCGXB6NN0z4rqc; Tue, 8 Mar 2022 00:33:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1646699610; 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=PeOFOs9voEzZ8Jze2gPExRdrFc1fj9efLNtfu/PIXk4=; b=L7HhPv5wuBvgjOJPshx779VkplxMnrfiMpY6BCo9FOZ9GNUlXq0X6dKpGPfPs9y4AbzrAO UuqLvYkfYH9w2hm9HVKVzZWNpPBPf9U7wglP/sqMnYOBtpScErvi55GNCz9yUynJSGXIkH AKDPgCqe+HXdYfcl1musq08qbVOa8NxrAc/Vt37CC2vPaOrC+bQGesir2k9cDR/boUmlR6 XqpDRuinAQSsGiBs/D4MYaOxcyOK8gkd6x0/mQ1U1ih821Ul75g+/pURWTEmH2DZVaw+7l 16gSM7xoHjLst+IxkFT2cLPGvCgdjDf9tn4ZDydLnWRbjVkN1feDOPsih42yOg== 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 BB2F712C25; Tue, 8 Mar 2022 00:33:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 2280XUTO088912; Tue, 8 Mar 2022 00:33:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 2280XUeE088911; Tue, 8 Mar 2022 00:33:30 GMT (envelope-from git) Date: Tue, 8 Mar 2022 00:33:30 GMT Message-Id: <202203080033.2280XUeE088911@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: 71f452d58c7a - stable/13 - zfs: Update test format strings to match variable typtes 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: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: 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: 71f452d58c7aa4625816015eec153718021b5db4 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1646699610; 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=PeOFOs9voEzZ8Jze2gPExRdrFc1fj9efLNtfu/PIXk4=; b=XSfDsuICaKM3+aSCdG6heXQH+l5UpDfeI5JPaVAyTOPV+88FPpmGM7KtZtNZ/alyqV3fNr t2hRmUAkU5bPu7FrkUwiATdCM3YZnYbkyZikxF2Hoyu5cB7cOKKHwFdROC+0ENLAvOYLA+ pFI+ILNRh+tEsYkGIfnBqLYI89hjJ6HM5giTfTWgEAclCsyXIXEduiaGRmIuRQC/4ccfm3 Wc0VZCBGkvUonDxTPRhd2ex3VaS14tX/bzOsgc2/zgX3s7fT/RUcr3fe/Vg5OEUNxFIIG6 5WLaziFxG9ipb5jPqMMTbftM6trFN1MYUdAbMUD08Xo7e7OJYPJIGjXIBX8Ogw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1646699610; a=rsa-sha256; cv=none; b=c7Hx/iUrzvKC6YKw27R7GRXaFD3UFmuWhZW19HJNYPvFeYSV3ixjsQko26odGNnEaw/t3C uBrqTWSCbv10fqkV0JwJ/VOIs1dRszfPpk8mbJ+FUCmkmnz2Tge3GwBeGPXzZBEBk68IzZ NU94fwCiclHLmNsVxUHA35BleXkULYJzvDPWsZJl1XcQ04wz+a7KS7ikd9oMNyeRPCHXxI cMzNK6CBvGmk+vyGDX6DE0Svjiyrb24NYmw5ZOfx/J//9e3bFgeDVt2Z6Cbah3FwKZhfqr tfOiVPxKWAbUFt0pen1B7sOF1yRMwKc3krqYwBUwW+bJjBzcaTVdapFX4T4Kxw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=71f452d58c7aa4625816015eec153718021b5db4 commit 71f452d58c7aa4625816015eec153718021b5db4 Author: Ed Maste AuthorDate: 2022-02-28 01:11:20 +0000 Commit: Ed Maste CommitDate: 2022-03-08 00:33:21 +0000 zfs: Update test format strings to match variable typtes And drop stray 'd' from the end of some printed numbers. I assume this was the result of someone thinking u is a printf length modifier for d, not a format specifier itself. Reviewed by: kevans, rew MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D34387 (cherry picked from commit f27fb06cadc6a8e75ebebd3b60c8a9dc9ae1b833) --- tests/sys/cddl/zfs/bin/readmmap.c | 8 ++++---- tests/sys/cddl/zfs/tests/ctime/ctime_001_pos.c | 4 ++-- tests/sys/cddl/zfs/tests/txg_integrity/fsync_integrity.c | 4 ++-- tests/sys/cddl/zfs/tests/txg_integrity/txg_integrity.c | 4 ++-- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/tests/sys/cddl/zfs/bin/readmmap.c b/tests/sys/cddl/zfs/bin/readmmap.c index 117246a8c2c4..d2dd5605351d 100644 --- a/tests/sys/cddl/zfs/bin/readmmap.c +++ b/tests/sys/cddl/zfs/bin/readmmap.c @@ -83,7 +83,7 @@ main(int argc, char **argv) bytes = write(fd, buf, size); if (bytes != size) { - (void) printf("short write: %d != %ud\n", bytes, size); + (void) printf("short write: %d != %zu\n", bytes, size); retval = 1; goto end; } @@ -114,20 +114,20 @@ main(int argc, char **argv) bytes = pread(fd, buf, size, 0); if (bytes != size) { - (void) printf("short read: %d != %ud\n", bytes, size); + (void) printf("short read: %d != %zu\n", bytes, size); retval = 1; goto end; } if (buf[idx] != 1) { (void) printf( - "bad data from read! got buf[%ud]=%d, expected 1\n", + "bad data from read! got buf[%zu]=%d, expected 1\n", idx, buf[idx]); retval = 1; goto end; } - (void) printf("good data from read: buf[%ud]=1\n", idx); + (void) printf("good data from read: buf[%zu]=1\n", idx); end: if (fd != -1) { (void) close(fd); diff --git a/tests/sys/cddl/zfs/tests/ctime/ctime_001_pos.c b/tests/sys/cddl/zfs/tests/ctime/ctime_001_pos.c index afccda1a8840..d858cebd26a8 100644 --- a/tests/sys/cddl/zfs/tests/ctime/ctime_001_pos.c +++ b/tests/sys/cddl/zfs/tests/ctime/ctime_001_pos.c @@ -227,7 +227,7 @@ do_read(const char *pfile) (void) close(fd); if (ret != 0) { - fprintf(stderr, "read(%d, buf, %d)\n", fd, sizeof (buf)); + fprintf(stderr, "read(%d, buf, %zu)\n", fd, sizeof (buf)); exit(1); } @@ -253,7 +253,7 @@ do_write(const char *pfile) (void) close(fd); if (ret != 0) { - fprintf(stderr, "write(%d, buf, %d)\n", fd, strlen(buf)); + fprintf(stderr, "write(%d, buf, %zu)\n", fd, strlen(buf)); exit(1); } diff --git a/tests/sys/cddl/zfs/tests/txg_integrity/fsync_integrity.c b/tests/sys/cddl/zfs/tests/txg_integrity/fsync_integrity.c index 0daba26579d4..b2d4bf0dc11a 100644 --- a/tests/sys/cddl/zfs/tests/txg_integrity/fsync_integrity.c +++ b/tests/sys/cddl/zfs/tests/txg_integrity/fsync_integrity.c @@ -332,7 +332,7 @@ verify_file(int fd, const pattern_t* p_pat){ int file_offset = chunk_start + chunk_offset; if (good_data && (actual_buf[i] != desired_buf[i])){ fprintf(stderr, "fsync_integrity: miscompare at " - "chunk %i, chunk offset %lx, file offset %lx\n", + "chunk %i, chunk offset %x, file offset %x\n", chunk_idx, chunk_offset, file_offset); fprintf(stderr, "Expected %016lx, got %016lx\n", desired_buf[i], actual_buf[i]); @@ -341,7 +341,7 @@ verify_file(int fd, const pattern_t* p_pat){ } else if (!good_data && (actual_buf[i] == desired_buf[i])) { fprintf(stderr, "fsync_integrity: miscompare ends at " - "chunk %i, chunk offset %lx, file offset %lx\n", + "chunk %i, chunk offset %x, file offset %x\n", chunk_idx, chunk_offset, file_offset); good_data = 1; } diff --git a/tests/sys/cddl/zfs/tests/txg_integrity/txg_integrity.c b/tests/sys/cddl/zfs/tests/txg_integrity/txg_integrity.c index 3200fca3bc90..ec1275dfccc0 100644 --- a/tests/sys/cddl/zfs/tests/txg_integrity/txg_integrity.c +++ b/tests/sys/cddl/zfs/tests/txg_integrity/txg_integrity.c @@ -370,7 +370,7 @@ verify_file(int fd, const pattern_t* p_pat){ int file_offset = chunk_start + chunk_offset; if (good_data && (actual_buf[i] != desired_buf[i])){ fprintf(stderr, "txg_integrity: miscompare at " - "chunk %i, chunk offset %lx, file offset %lx\n", + "chunk %i, chunk offset %x, file offset %x\n", chunk_idx, chunk_offset, file_offset); fprintf(stderr, "Expected %16lx, got %16lx\n", desired_buf[i], actual_buf[i]); @@ -379,7 +379,7 @@ verify_file(int fd, const pattern_t* p_pat){ } else if (!good_data && (actual_buf[i] == desired_buf[i])) { fprintf(stderr, "txg_integrity: miscompare ends at " - "chunk %i, chunk offset %lx, file offset %lx\n", + "chunk %i, chunk offset %x, file offset %x\n", chunk_idx, chunk_offset, file_offset); good_data = 1; }