Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sbin/iscsid Don't try to print pointers as integers, use %p ...
details: https://anonhg.NetBSD.org/src/rev/569f105375d9
branches: trunk
changeset: 779422:569f105375d9
user: riz <riz%NetBSD.org@localhost>
date: Sun May 27 16:50:32 2012 +0000
description:
Don't try to print pointers as integers, use %p instead and don't cast.
diffstat:
sbin/iscsid/iscsid_driverif.c | 6 +++---
sbin/iscsid/iscsid_lists.c | 6 +++---
sbin/iscsid/iscsid_targets.c | 4 ++--
3 files changed, 8 insertions(+), 8 deletions(-)
diffs (60 lines):
diff -r 4b6868b8cc8a -r 569f105375d9 sbin/iscsid/iscsid_driverif.c
--- a/sbin/iscsid/iscsid_driverif.c Sun May 27 13:25:28 2012 +0000
+++ b/sbin/iscsid/iscsid_driverif.c Sun May 27 16:50:32 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: iscsid_driverif.c,v 1.3 2011/11/20 01:23:57 agc Exp $ */
+/* $NetBSD: iscsid_driverif.c,v 1.4 2012/05/27 16:50:32 riz Exp $ */
/*-
* Copyright (c) 2005,2006,2011 The NetBSD Foundation, Inc.
@@ -192,8 +192,8 @@
struct hostent *host;
initiator_t *init;
- DEB(9, ("Make Connection sess=%x, req=%x, res=%x, stid=%x\n",
- (int) sess, (int) req, (int) res, (int) stid));
+ DEB(9, ("Make Connection sess=%p, req=%p, res=%p, stid=%p\n",
+ sess, req, res, stid));
(void) memset(&loginp, 0x0, sizeof(loginp));
(void) memset(&serverAddress, 0x0, sizeof(serverAddress));
diff -r 4b6868b8cc8a -r 569f105375d9 sbin/iscsid/iscsid_lists.c
--- a/sbin/iscsid/iscsid_lists.c Sun May 27 13:25:28 2012 +0000
+++ b/sbin/iscsid/iscsid_lists.c Sun May 27 16:50:32 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: iscsid_lists.c,v 1.3 2011/11/20 01:23:57 agc Exp $ */
+/* $NetBSD: iscsid_lists.c,v 1.4 2012/05/27 16:50:32 riz Exp $ */
/*-
* Copyright (c) 2005,2006,2011 The NetBSD Foundation, Inc.
@@ -256,10 +256,10 @@
TAILQ_FOREACH(curr, &list[PORTAL_LIST].list, link) {
p = (void *)curr;
- DEB(10, ("Find_portal_by_addr - addr %s port %d target %x\n",
+ DEB(10, ("Find_portal_by_addr - addr %s port %d target %p\n",
p->addr.address,
p->addr.port,
- (int) p->target));
+ p->target));
if (strcmp((char *)p->addr.address, (char *)addr->address) == 0 &&
(!addr->port || p->addr.port == addr->port) &&
diff -r 4b6868b8cc8a -r 569f105375d9 sbin/iscsid/iscsid_targets.c
--- a/sbin/iscsid/iscsid_targets.c Sun May 27 13:25:28 2012 +0000
+++ b/sbin/iscsid/iscsid_targets.c Sun May 27 16:50:32 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: iscsid_targets.c,v 1.3 2011/11/20 01:23:57 agc Exp $ */
+/* $NetBSD: iscsid_targets.c,v 1.4 2012/05/27 16:50:32 riz Exp $ */
/*-
* Copyright (c) 2005,2006,2011 The NetBSD Foundation, Inc.
@@ -114,7 +114,7 @@
TAILQ_INSERT_TAIL(&list[PORTAL_LIST].list, &portal->entry, link);
list[PORTAL_LIST].num_entries++;
- DEB(9, ("create_portal returns %x\n", (int) portal));
+ DEB(9, ("create_portal returns %p\n", portal));
return portal;
}
Home |
Main Index |
Thread Index |
Old Index