try to reload only when mc_deck is available
comment modified
This commit is contained in:
parent
b0537d7019
commit
9cc690c55c
|
|
@ -468,7 +468,7 @@ inp_spsource(FILE *fp, bool comfile, char *filename, bool intfile)
|
|||
/* called with *fp == NULL and not intfile: we want to reload circuit from mc_deck */
|
||||
else {
|
||||
/* re-load deck due to command 'reset' via function inp_source_recent() */
|
||||
if (mc_reload) {
|
||||
if (mc_reload && mc_deck) {
|
||||
deck = inp_deckcopy(mc_deck);
|
||||
expr_w_temper = TRUE;
|
||||
mc_reload = FALSE;
|
||||
|
|
@ -479,14 +479,14 @@ inp_spsource(FILE *fp, bool comfile, char *filename, bool intfile)
|
|||
deck = inp_deckcopy(ft_curckt->ci_mcdeck);
|
||||
expr_w_temper = TRUE;
|
||||
}
|
||||
/* re-load input deck from the recent circuit structure */
|
||||
/* re-load input deck from the recent circuit structure with mc_source */
|
||||
else if (!ft_curckt && mc_deck) {
|
||||
deck = inp_deckcopy(mc_deck);
|
||||
expr_w_temper = TRUE;
|
||||
}
|
||||
/* no circuit available, should not happen */
|
||||
else {
|
||||
fprintf(stderr, "Error: No circuit loaded, cannot copy internally using mc_source\n");
|
||||
fprintf(stderr, "Error: No circuit loaded, cannot copy internally using mc_source or reset\n");
|
||||
controlled_exit(1);
|
||||
}
|
||||
/* print out the re-loaded deck into debug-out-mc.txt */
|
||||
|
|
|
|||
Loading…
Reference in New Issue