aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <zecke@selfish.org>2010-03-30 08:41:17 +0200
committerHolger Hans Peter Freyther <zecke@selfish.org>2010-03-30 08:41:17 +0200
commit18bbe2e8a012be195069fad7224121ab64953fec (patch)
treee983e1b94b9a2fe987459afc10c7a456b972fb0d
parent1b17913cbc75fc8fd96b5ffae14ec462e2d7c010 (diff)
misc: Do not prepend 0x when using %p in printf.
-rw-r--r--openbsc/src/bssap.c2
-rw-r--r--openbsc/src/nat/bsc_sccp.c8
-rw-r--r--openbsc/tests/bsc-nat/bsc_nat_test.c10
3 files changed, 10 insertions, 10 deletions
diff --git a/openbsc/src/bssap.c b/openbsc/src/bssap.c
index abcb6ac85..fac6c1f57 100644
--- a/openbsc/src/bssap.c
+++ b/openbsc/src/bssap.c
@@ -449,7 +449,7 @@ static void continue_new_assignment(struct gsm_lchan *new_lchan)
return;
}
- LOGP(DMSC, LOGL_NOTICE, "Sending assignment on chan: 0x%p\n", new_lchan);
+ LOGP(DMSC, LOGL_NOTICE, "Sending assignment on chan: %p\n", new_lchan);
gsm48_send_rr_ass_cmd(new_lchan->msc_data->lchan, new_lchan, 0x3);
}
diff --git a/openbsc/src/nat/bsc_sccp.c b/openbsc/src/nat/bsc_sccp.c
index eed80305c..fe85a5dd6 100644
--- a/openbsc/src/nat/bsc_sccp.c
+++ b/openbsc/src/nat/bsc_sccp.c
@@ -101,7 +101,7 @@ int create_sccp_src_ref(struct bsc_connection *bsc, struct msgb *msg, struct bsc
llist_add(&conn->list_entry, &bsc->nat->sccp_connections);
- LOGP(DNAT, LOGL_DEBUG, "Created 0x%x <-> 0x%x mapping for con 0x%p\n",
+ LOGP(DNAT, LOGL_DEBUG, "Created 0x%x <-> 0x%x mapping for con %p\n",
sccp_src_ref_to_int(&conn->real_ref),
sccp_src_ref_to_int(&conn->patched_ref), bsc);
@@ -126,13 +126,13 @@ int update_sccp_src_ref(struct bsc_connection *bsc, struct msgb *msg, struct bsc
continue;
conn->remote_ref = *parsed->src_local_ref;
- LOGP(DNAT, LOGL_DEBUG, "Updating 0x%x to remote 0x%x on 0x%p\n",
+ LOGP(DNAT, LOGL_DEBUG, "Updating 0x%x to remote 0x%x on %p\n",
sccp_src_ref_to_int(&conn->patched_ref),
sccp_src_ref_to_int(&conn->remote_ref), bsc);
return 0;
}
- LOGP(DNAT, LOGL_ERROR, "Referenced connection not found on BSC: 0x%p\n", bsc);
+ LOGP(DNAT, LOGL_ERROR, "Referenced connection not found on BSC: %p\n", bsc);
return -1;
}
@@ -148,7 +148,7 @@ void remove_sccp_src_ref(struct bsc_connection *bsc, struct msgb *msg, struct bs
if (bsc != conn->bsc)
continue;
- LOGP(DNAT, LOGL_DEBUG, "Destroy 0x%x <-> 0x%x mapping for con 0x%p\n",
+ LOGP(DNAT, LOGL_DEBUG, "Destroy 0x%x <-> 0x%x mapping for con %p\n",
sccp_src_ref_to_int(&conn->real_ref),
sccp_src_ref_to_int(&conn->patched_ref), bsc);
llist_del(&conn->list_entry);
diff --git a/openbsc/tests/bsc-nat/bsc_nat_test.c b/openbsc/tests/bsc-nat/bsc_nat_test.c
index 966667e3c..196f187d8 100644
--- a/openbsc/tests/bsc-nat/bsc_nat_test.c
+++ b/openbsc/tests/bsc-nat/bsc_nat_test.c
@@ -190,7 +190,7 @@ static void copy_to_msg(struct msgb *msg, const u_int8_t *data, unsigned int len
#define VERIFY(con_found, con, msg, ver, str) \
if (con_found != con) { \
- fprintf(stderr, "Failed to find the con: 0x%p\n", con_found); \
+ fprintf(stderr, "Failed to find the con: %p\n", con_found); \
abort(); \
} \
if (memcmp(msg->data, ver, sizeof(ver)) != 0) { \
@@ -217,7 +217,7 @@ static void test_contrack()
parsed = bsc_nat_parse(msg);
con_found = patch_sccp_src_ref_to_msc(msg, parsed, nat);
if (con_found != NULL) {
- fprintf(stderr, "Con should not exist 0x%p\n", con_found);
+ fprintf(stderr, "Con should not exist %p\n", con_found);
abort();
}
rc = create_sccp_src_ref(con, msg, parsed);
@@ -227,7 +227,7 @@ static void test_contrack()
}
con_found = patch_sccp_src_ref_to_msc(msg, parsed, nat);
if (con_found != con) {
- fprintf(stderr, "Failed to find the con: 0x%p\n", con_found);
+ fprintf(stderr, "Failed to find the con: %p\n", con_found);
abort();
}
if (memcmp(msg->data, bsc_cr_patched, sizeof(bsc_cr_patched)) != 0) {
@@ -269,7 +269,7 @@ static void test_contrack()
parsed = bsc_nat_parse(msg);
con_found = patch_sccp_src_ref_to_msc(msg, parsed, nat);
if (con_found != con) {
- fprintf(stderr, "Failed to find the con: 0x%p\n", con_found);
+ fprintf(stderr, "Failed to find the con: %p\n", con_found);
abort();
}
if (memcmp(msg->data, bsc_rlc_patched, sizeof(bsc_rlc_patched)) != 0) {
@@ -281,7 +281,7 @@ static void test_contrack()
/* verify that it is gone */
if (con_found != NULL) {
- fprintf(stderr, "Con should be gone. 0x%p\n", con_found);
+ fprintf(stderr, "Con should be gone. %p\n", con_found);
abort();
}
talloc_free(parsed);