Commit 4e1fd7f77dc6eaff75e6581a7dbce84e6d4da524
authorDaniël Geelen <daniel.geelen+github@gmail.com>
Wed, 18 Apr 2018 06:33:58 +0000 (08:33 +0200)
committerDaniël Geelen <daniel.geelen+github@gmail.com>
Sat, 21 Apr 2018 18:56:59 +0000 (20:56 +0200)
simavr/sim/sim_vcd_file.c

index 246ae7c6f25b1390952788529f283bac5fcc6da7..9320a9f12fc809e32705a7b41a44871094312618 100644 (file)
@@ -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));