Browse Source

logging: Print category + level, disable category-hex

Change-Id: I9ae27b78b965d173146583b030fd93e2d70b845e
changes/72/26472/4
Harald Welte 8 months ago
parent
commit
73bbd54cdb
  1. 5
      src/bankd/bankd_main.c
  2. 6
      src/client/remsim_client_main.c
  3. 6
      src/server/remsim_server.c

5
src/bankd/bankd_main.c

@ -39,6 +39,7 @@
#include <osmocom/core/linuxlist.h>
#include <osmocom/core/logging.h>
#include <osmocom/core/application.h>
#include <osmocom/core/fsm.h>
#include <osmocom/gsm/ipa.h>
#include <osmocom/gsm/protocol/ipaccess.h>
@ -75,6 +76,10 @@ static void bankd_init(struct bankd *bankd)
{
g_tall_ctx = talloc_named_const(NULL, 0, "global");
osmo_init_logging2(g_tall_ctx, &log_info);
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);
osmo_fsm_log_addr(0);
asn_debug = 0;

6
src/client/remsim_client_main.c

@ -6,6 +6,8 @@
#include <getopt.h>
#include <osmocom/core/msgb.h>
#include <osmocom/core/logging.h>
#include <osmocom/core/fsm.h>
#include <osmocom/core/application.h>
#include "client.h"
@ -169,6 +171,10 @@ int main(int argc, char **argv)
msgb_talloc_ctx_init(g_tall_ctx, 0);
osmo_init_logging2(g_tall_ctx, &log_info);
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);
osmo_fsm_log_addr(0);
cfg = client_config_init(g_tall_ctx);
OSMO_ASSERT(cfg);

6
src/server/remsim_server.c

@ -8,6 +8,8 @@
#include <osmocom/core/utils.h>
#include <osmocom/core/talloc.h>
#include <osmocom/core/logging.h>
#include <osmocom/core/fsm.h>
#include <osmocom/core/application.h>
#include <osmocom/core/select.h>
@ -87,6 +89,10 @@ int main(int argc, char **argv)
msgb_talloc_ctx_init(g_tall_ctx, 0);
osmo_init_logging2(g_tall_ctx, &log_info);
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);
osmo_fsm_log_addr(0);
handle_options(argc, argv);

Loading…
Cancel
Save