@ -18,7 +18,7 @@ com_option(wordlist *wl)
CKTcircuit *circuit = NULL;
if (!ft_curckt) {
if (!ft_curckt || !ft_curckt->ci_ckt) {
fprintf(cp_err, "Error: no circuit loaded\n");
return;
}
@ -30,7 +30,7 @@ com_inventory(wordlist *wl)
NG_IGNORE(wl);
fprintf(cp_err, "There is no current circuit\n");
@ -430,7 +430,7 @@ cp_usrset(struct variable *var, bool isset)
return (0);
if (ft_curckt) {
if (ft_curckt && ft_curckt->ci_ckt) {
if (if_option(ft_curckt->ci_ckt, var->va_name, var->va_type, vv))
return US_SIMVAR;
} else {