diff options
| author | Rafael Zalamena <rzalamena@opensourcerouting.org> | 2018-08-16 15:47:34 -0300 | 
|---|---|---|
| committer | Rafael Zalamena <rzalamena@opensourcerouting.org> | 2018-08-16 18:33:32 -0300 | 
| commit | 3bcd76c4af51b9883207514fdc8ff42877680a89 (patch) | |
| tree | 2ae83681535313550cae0df6ef6e4d295ce4de49 /bfdd/control.c | |
| parent | 7efe273ae4a30b7e617678a9a1933cbfcf8608e1 (diff) | |
bfdd: fix coverity scan issue (CID 1472622)
Don't use the stack variable, but what we have recorded in our buffered
data on the heap.
Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
Diffstat (limited to 'bfdd/control.c')
| -rw-r--r-- | bfdd/control.c | 6 | 
1 files changed, 3 insertions, 3 deletions
diff --git a/bfdd/control.c b/bfdd/control.c index 7e586dbb45..554a5a8d80 100644 --- a/bfdd/control.c +++ b/bfdd/control.c @@ -514,7 +514,7 @@ skip_header:  	if (bcb->bcb_left > 0)  		goto schedule_next_read; -	switch (bcm.bcm_type) { +	switch (bcb->bcb_bcm->bcm_type) {  	case BMT_REQUEST_ADD:  		control_handle_request_add(bcs, bcb->bcb_bcm);  		break; @@ -533,8 +533,8 @@ skip_header:  	default:  		log_debug("%s: unhandled message type: %d", __func__, -			  bcm.bcm_type); -		control_response(bcs, bcm.bcm_id, BCM_RESPONSE_ERROR, +			  bcb->bcb_bcm->bcm_type); +		control_response(bcs, bcb->bcb_bcm->bcm_id, BCM_RESPONSE_ERROR,  				 "invalid message type");  		break;  	}  | 
