Il 10/06/2014 13:43, Cornelia Huck ha scritto:
> +    CPUState *cs = qemu_get_cpu(monitor_get_cpu_index());
> +    CPUClass *cc = CPU_GET_CLASS(cs);
Just wondering: Is CPU_GET_CLASS(NULL) really safe?

No, it's not...

> +
> +    if (cs && cc->nmi_monitor_handler) {
Or is cs == NULL simply not possible, and the code should check for
cc != NULL here instead?

... and cc cannot be NULL either here.

Paolo

> +        cc->nmi_monitor_handler(cs, errp);


Reply via email to