Skip to content

Commit 5b24b6b

Browse files
committed
session BUGFIX check for errors when generating capabilities
Fixes #271
1 parent 5fb5f99 commit 5b24b6b

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

src/session.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1287,6 +1287,9 @@ nc_send_hello_io(struct nc_session *session)
12871287
sid = NULL;
12881288
} else {
12891289
cpblts = nc_server_get_cpblts_version(session->ctx, LYS_VERSION_1);
1290+
if (!cpblts) {
1291+
return NC_MSG_ERROR;
1292+
}
12901293

12911294
io_timeout = NC_SERVER_HELLO_TIMEOUT * 1000;
12921295
sid = &session->id;

0 commit comments

Comments
 (0)