cosmetic improvement in log statements
This commit is contained in:
parent
b179934a8b
commit
98d65dbb2e
11
capi.c
11
capi.c
|
@ -79,7 +79,7 @@ static void cb_free(void *buf)
|
||||||
static void cb_disconnected(capi_connection *cp, int localdisconnect, unsigned reason, unsigned reason_b3)
|
static void cb_disconnected(capi_connection *cp, int localdisconnect, unsigned reason, unsigned reason_b3)
|
||||||
{
|
{
|
||||||
struct call_state *cst;
|
struct call_state *cst;
|
||||||
LOGP(DCAPI, LOGL_DEBUG, "%s(local=%d, reason=0x%4x, reason_b3=0x%x)\n", __func__, localdisconnect, reason, reason_b3);
|
LOGP(DCAPI, LOGL_DEBUG, "%s(local=%d, reason=0x%04x, reason_b3=0x%04x)\n", __func__, localdisconnect, reason, reason_b3);
|
||||||
|
|
||||||
cst = capiconn_getpriv(cp);
|
cst = capiconn_getpriv(cp);
|
||||||
OSMO_ASSERT(cst);
|
OSMO_ASSERT(cst);
|
||||||
|
@ -95,7 +95,7 @@ static void cb_incoming(capi_connection *cp, unsigned contr, unsigned cipvalue,
|
||||||
|
|
||||||
/* we should call capiconn_{accept,ignore,reject} */
|
/* we should call capiconn_{accept,ignore,reject} */
|
||||||
|
|
||||||
LOGP(DCAPI, LOGL_INFO, "incoming call: %s (0x%x) %s -> %s\n",
|
LOGP(DCAPI, LOGL_INFO, "incoming call: %s (CIP=%u) %s -> %s\n",
|
||||||
conninfo(cp), cipvalue, calling, called);
|
conninfo(cp), cipvalue, calling, called);
|
||||||
|
|
||||||
bch = bchan_handler_for_call(cipvalue, called);
|
bch = bchan_handler_for_call(cipvalue, called);
|
||||||
|
@ -291,7 +291,7 @@ static const struct log_info_cat log_info_cat[] = {
|
||||||
.loglevel = LOGL_DEBUG,
|
.loglevel = LOGL_DEBUG,
|
||||||
},
|
},
|
||||||
[DLCAPI20] = {
|
[DLCAPI20] = {
|
||||||
.name = "DLCAPI02",
|
.name = "DLCAPI",
|
||||||
.description = "ISDN libcapi20",
|
.description = "ISDN libcapi20",
|
||||||
.enabled = 1,
|
.enabled = 1,
|
||||||
.loglevel = LOGL_DEBUG,
|
.loglevel = LOGL_DEBUG,
|
||||||
|
@ -309,6 +309,11 @@ int main(int argc, char **argv)
|
||||||
void *ctx = talloc_named_const(NULL, 1, "capi-test");
|
void *ctx = talloc_named_const(NULL, 1, "capi-test");
|
||||||
|
|
||||||
osmo_init_logging2(ctx, &log_info);
|
osmo_init_logging2(ctx, &log_info);
|
||||||
|
log_set_use_color(osmo_stderr_target, 1);
|
||||||
|
log_set_print_level(osmo_stderr_target, 1);
|
||||||
|
log_set_print_category(osmo_stderr_target, 1);
|
||||||
|
log_set_print_category_hex(osmo_stderr_target, 0);
|
||||||
|
log_set_print_filename_pos(osmo_stderr_target, LOG_FILENAME_POS_LINE_END);
|
||||||
capi_init(ctx);
|
capi_init(ctx);
|
||||||
|
|
||||||
bchan_route_add(-1, "142", "raw_prbs");
|
bchan_route_add(-1, "142", "raw_prbs");
|
||||||
|
|
Loading…
Reference in New Issue