nhrpd: uninitialized variable (Clang scan)

This correction fixes two bugs detected by Clang scan:

Bug Group: Logic error
Bug Type: Assigned value is garbage or undefined
File: nhrpd/vici.c
Function: vici_parse_message
Lines: 100, 105

Signed-off-by: F. Aragon <paco@voltanet.io>
This commit is contained in:
F. Aragon 2018-06-29 16:51:08 +02:00
parent 62a9c814e1
commit 0a939f4f24
No known key found for this signature in database
GPG Key ID: FD112A8C7E6A5E4A

View File

@ -287,6 +287,7 @@ static void vici_recv_sa(struct vici_conn *vici, struct zbuf *msg, int event)
char buf[32];
struct handle_sa_ctx ctx = {
.event = event,
.msgctx.nsections = 0
};
vici_parse_message(vici, msg, parse_sa_message, &ctx.msgctx);