Index: obj_subc.h =================================================================== --- obj_subc.h (revision 22623) +++ obj_subc.h (revision 22624) @@ -131,8 +131,9 @@ void *pcb_subc_remove(pcb_subc_t *sc); /* In board mode return brd_layer; in footprint edit mode, return the subcircuit - layer that matches brd_layer or brd_layer if not found. */ -pcb_layer_t *pcb_loose_subc_layer(pcb_board_t *pcb, pcb_layer_t *brd_layer); + layer that matches brd_layer. If not found, either allocate it within + the subc (if alloc is true) or return the brd_layer. */ +pcb_layer_t *pcb_loose_subc_layer(pcb_board_t *pcb, pcb_layer_t *brd_layer, pcb_bool alloc); /* Returns whether there's no object in the subc */ pcb_bool pcb_subc_is_empty(pcb_subc_t *subc);