Found a crash condition reported by Abhinav Uppal where labels
that are unattached (type = space) will cause magic to crash on the command "lef write -hide"---The lowest level issue was in SelectChunk(), so for good measure SelectChunk() now checks for type == TT_SPACE, and "lef write" does also.
This commit is contained in:
parent
a550d615c0
commit
f12a155ea7
|
|
@ -1442,8 +1442,10 @@ lefWriteMacro(def, f, scale, setback, pinonly, toplayer, domaster)
|
|||
/* SelectDef. */
|
||||
|
||||
pNum = DBPlane(lab->lab_type);
|
||||
DBPaintPlane(SelectDef->cd_planes[pNum], &carea,
|
||||
DBStdPaintTbl(lab->lab_type, pNum), (PaintUndoInfo *) NULL);
|
||||
if (pNum >= 0)
|
||||
DBPaintPlane(SelectDef->cd_planes[pNum], &carea,
|
||||
DBStdPaintTbl(lab->lab_type, pNum),
|
||||
(PaintUndoInfo *) NULL);
|
||||
|
||||
/* Remember this area since it's going to get erased */
|
||||
newlll = (labelLinkedList *)mallocMagic(sizeof(labelLinkedList));
|
||||
|
|
|
|||
|
|
@ -715,6 +715,9 @@ SelectChunk(scx, type, xMask, pArea, less)
|
|||
SelSetDisplay(SelectUse, SelectRootDef);
|
||||
}
|
||||
|
||||
/* Ignore if type is TT_SPACE */
|
||||
if (type == TT_SPACE) return;
|
||||
|
||||
/* The chunk is computed iteratively. First extract a small
|
||||
* region (defined by INITIALSIZE) into Select2Def. Then find
|
||||
* the largest chunk in the region. If the chunk touches a
|
||||
|
|
|
|||
Loading…
Reference in New Issue