From 6e8c0884729eedbf4fc66414b67300d505ac17bb Mon Sep 17 00:00:00 2001 From: Neels Hofmeyr Date: Mon, 9 Apr 2018 02:28:34 +0200 Subject: cosmetic: osmo_fsm_inst_update_id(): don't log "allocate" On erratic id in osmo_fsm_inst_update_id(), don't say "Attempting to allocate FSM instance". Escape the invalid id using osmo_quote_str(). Change-Id: I770fc460de21faa42b403f694e853e8da01c4bef --- src/fsm.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/fsm.c') diff --git a/src/fsm.c b/src/fsm.c index 9bbf870e..0fdc564d 100644 --- a/src/fsm.c +++ b/src/fsm.c @@ -213,8 +213,9 @@ int osmo_fsm_inst_update_id(struct osmo_fsm_inst *fi, const char *id) { if (id) { if (!osmo_identifier_valid(id)) { - LOGP(DLGLOBAL, LOGL_ERROR, "Attempting to allocate FSM instance of type '%s'" - " with illegal identifier '%s'\n", fi->fsm->name, id); + LOGP(DLGLOBAL, LOGL_ERROR, + "Attempting to set illegal id for FSM instance of type '%s': %s\n", + fi->fsm->name, osmo_quote_str(id, -1)); return -EINVAL; } osmo_talloc_replace_string(fi, (char **)&fi->id, id); -- cgit v1.2.3