Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 31 Dec 2020 19:42:41 GMT
From:      John Baldwin <jhb@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: e36ac668971c - stable/12 - Use the 't' modifier to print a ptrdiff_t.
Message-ID:  <202012311942.0BVJgfDk075193@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch stable/12 has been updated by jhb:

URL: https://cgit.FreeBSD.org/src/commit/?id=e36ac668971c1bdf97e099bda88cb9cae3ea74c9

commit e36ac668971c1bdf97e099bda88cb9cae3ea74c9
Author:     John Baldwin <jhb@FreeBSD.org>
AuthorDate: 2020-12-16 00:11:30 +0000
Commit:     John Baldwin <jhb@FreeBSD.org>
CommitDate: 2020-12-31 18:54:49 +0000

    Use the 't' modifier to print a ptrdiff_t.
    
    Obtained from:  CheriBSD
    Sponsored by:   DARPA
    
    (cherry picked from commit ce8395ecfda2c8e332a2adf9a9432c2e7f35ea81)
---
 sys/compat/linuxkpi/common/include/linux/printk.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sys/compat/linuxkpi/common/include/linux/printk.h b/sys/compat/linuxkpi/common/include/linux/printk.h
index 31802bdd2c99..e6510e9e9834 100644
--- a/sys/compat/linuxkpi/common/include/linux/printk.h
+++ b/sys/compat/linuxkpi/common/include/linux/printk.h
@@ -68,7 +68,7 @@ print_hex_dump(const char *level, const char *prefix_str,
 			printf("[%p] ", buf);
 			break;
 		case DUMP_PREFIX_OFFSET:
-			printf("[%p] ", (const char *)((const char *)buf -
+			printf("[%#tx] ", ((const char *)buf -
 			    (const char *)buf_old));
 			break;
 		default:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202012311942.0BVJgfDk075193>