Skip to content

Commit 69e9875

Browse files
committed
session BUGFIX message parameter fixes
1 parent 25e244b commit 69e9875

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

src/session.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ nc_session_rpc_unlock(struct nc_session *session, int timeout, const char *func)
370370
ERR(session, "%s: failed to RPC lock a session (%s).", func, strerror(ret));
371371
return -1;
372372
} else if (ret) {
373-
WRN(session, "%s: session RPC lock timeout, should not happen.");
373+
WRN(session, "%s: session RPC lock timeout, should not happen.", func);
374374
}
375375

376376
session->opts.server.rpc_inuse = 0;

src/session_client.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2700,7 +2700,7 @@ nc_send_rpc(struct nc_session *session, struct nc_rpc *rpc, int timeout, uint64_
27002700
if (rpc_gc->wd_mode) {
27012701
ietfncwd = ly_ctx_get_module_implemented(session->ctx, "ietf-netconf-with-defaults");
27022702
if (!ietfncwd) {
2703-
ERR(session, "Missing \"ietf-netconf-with-defaults\" module in the context.", session->id);
2703+
ERR(session, "Missing \"ietf-netconf-with-defaults\" module in the context.");
27042704
lyrc = LY_ENOTFOUND;
27052705
break;
27062706
}
@@ -2756,7 +2756,7 @@ nc_send_rpc(struct nc_session *session, struct nc_rpc *rpc, int timeout, uint64_
27562756
if (rpc_cp->wd_mode) {
27572757
ietfncwd = ly_ctx_get_module_implemented(session->ctx, "ietf-netconf-with-defaults");
27582758
if (!ietfncwd) {
2759-
ERR(session, "Missing \"ietf-netconf-with-defaults\" module in the context.", session->id);
2759+
ERR(session, "Missing \"ietf-netconf-with-defaults\" module in the context.");
27602760
lyrc = LY_ENOTFOUND;
27612761
break;
27622762
}
@@ -2810,7 +2810,7 @@ nc_send_rpc(struct nc_session *session, struct nc_rpc *rpc, int timeout, uint64_
28102810
if (rpc_g->wd_mode) {
28112811
ietfncwd = ly_ctx_get_module_implemented(session->ctx, "ietf-netconf-with-defaults");
28122812
if (!ietfncwd) {
2813-
ERR(session, "Missing \"ietf-netconf-with-defaults\" module in the context.", session->id);
2813+
ERR(session, "Missing \"ietf-netconf-with-defaults\" module in the context.");
28142814
lyrc = LY_ENOTFOUND;
28152815
break;
28162816
}

src/session_server.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -392,7 +392,7 @@ sock_host_inet(const struct sockaddr_in *addr, char **host, uint16_t *port)
392392
}
393393

394394
if (!inet_ntop(AF_INET, &addr->sin_addr, *host, INET_ADDRSTRLEN)) {
395-
ERR(NULL, "inet_ntop failed(%s).");
395+
ERR(NULL, "inet_ntop failed (%s).", strerror(errno));
396396
free(*host);
397397
*host = NULL;
398398
return -1;
@@ -421,7 +421,7 @@ sock_host_inet6(const struct sockaddr_in6 *addr, char **host, uint16_t *port)
421421
}
422422

423423
if (!inet_ntop(AF_INET6, &addr->sin6_addr, *host, INET6_ADDRSTRLEN)) {
424-
ERR(NULL, "inet_ntop failed(%s).");
424+
ERR(NULL, "inet_ntop failed (%s).", strerror(errno));
425425
free(*host);
426426
*host = NULL;
427427
return -1;

0 commit comments

Comments
 (0)