From 4e1fd7f77dc6eaff75e6581a7dbce84e6d4da524 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Dani=C3=ABl=20Geelen?= Date: Wed, 18 Apr 2018 08:33:58 +0200 Subject: [PATCH] Log more warnings for VCD functionality. --- simavr/sim/sim_vcd_file.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/simavr/sim/sim_vcd_file.c b/simavr/sim/sim_vcd_file.c index 246ae7c..9320a9f 100644 --- a/simavr/sim/sim_vcd_file.c +++ b/simavr/sim/sim_vcd_file.c @@ -450,8 +450,12 @@ _avr_vcd_notify( { avr_vcd_t * vcd = (avr_vcd_t *)param; - if (!vcd->output) + if (!vcd->output) { + AVR_LOG(vcd->avr, LOG_WARNING, + "%s: no output\n", + __FUNCTION__); return; + } avr_vcd_signal_t * s = (avr_vcd_signal_t*)irq; avr_vcd_log_t l = { @@ -478,8 +482,12 @@ avr_vcd_add_signal( int signal_bit_size, const char * name ) { - if (vcd->signal_count == AVR_VCD_MAX_SIGNALS) + if (vcd->signal_count == AVR_VCD_MAX_SIGNALS) { + AVR_LOG(vcd->avr, LOG_ERROR, + " %s: unable add signal '%s'\n", + __FUNCTION__, name); return -1; + } int index = vcd->signal_count++; avr_vcd_signal_t * s = &vcd->signal[index]; strncpy(s->name, name, sizeof(s->name)); -- 2.39.5