Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/external/cddl/osnet/dist Fix migrating to snprintf_blkptr
details: https://anonhg.NetBSD.org/src/rev/6769c27c146d
branches: trunk
changeset: 328148:6769c27c146d
user: ozaki-r <ozaki-r%NetBSD.org@localhost>
date: Fri Mar 28 03:18:24 2014 +0000
description:
Fix migrating to snprintf_blkptr
diffstat:
external/cddl/osnet/dist/cmd/zdb/zdb.c | 2 +-
external/cddl/osnet/dist/uts/common/fs/zfs/sys/spa.h | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diffs (33 lines):
diff -r 1065861f5587 -r 6769c27c146d external/cddl/osnet/dist/cmd/zdb/zdb.c
--- a/external/cddl/osnet/dist/cmd/zdb/zdb.c Fri Mar 28 03:11:00 2014 +0000
+++ b/external/cddl/osnet/dist/cmd/zdb/zdb.c Fri Mar 28 03:18:24 2014 +0000
@@ -1427,7 +1427,7 @@
len = snprintf(blkbuf, blklen, ", rootbp ");
if (len > blklen)
len = blklen;
- printf_blkptr(blkbuf + len, blklen - len, os->os_rootbp);
+ snprintf_blkptr(blkbuf + len, blklen - len, os->os_rootbp);
} else {
blkbuf[0] = '\0';
}
diff -r 1065861f5587 -r 6769c27c146d external/cddl/osnet/dist/uts/common/fs/zfs/sys/spa.h
--- a/external/cddl/osnet/dist/uts/common/fs/zfs/sys/spa.h Fri Mar 28 03:11:00 2014 +0000
+++ b/external/cddl/osnet/dist/uts/common/fs/zfs/sys/spa.h Fri Mar 28 03:18:24 2014 +0000
@@ -592,7 +592,7 @@
extern void spa_strfree(char *);
extern uint64_t spa_get_random(uint64_t range);
extern uint64_t spa_generate_guid(spa_t *spa);
-extern void sprintf_blkptr(char *buf, const blkptr_t *bp);
+extern void snprintf_blkptr(char *buf, const blkptr_t *bp);
extern void spa_freeze(spa_t *spa);
extern void spa_upgrade(spa_t *spa, uint64_t version);
extern void spa_evict_all(void);
@@ -672,7 +672,7 @@
#define dprintf_bp(bp, fmt, ...) do { \
if (zfs_flags & ZFS_DEBUG_DPRINTF) { \
char *__blkbuf = kmem_alloc(BP_SPRINTF_LEN, KM_SLEEP); \
- sprintf_blkptr(__blkbuf, (bp)); \
+ snprintf_blkptr(__blkbuf, BP_SPRINTF_LEN, (bp)); \
dprintf(fmt " %s\n", __VA_ARGS__, __blkbuf); \
kmem_free(__blkbuf, BP_SPRINTF_LEN); \
} \
Home |
Main Index |
Thread Index |
Old Index