Fixed Coverity reported issue
CID 11441: Non-array delete for scalars (DELETE_ARRAY) "_dwobj::readOpenings(_iobuf *, int)" allocates "obj.fc1". [show details] "_dwobj::~_dwobj()" uses delete on "obj.fc1" which is an array. It should be deleted with operator delete[]. [show details]
This commit is contained in:
parent
07bed106af
commit
3d300c38d0
@ -524,7 +524,7 @@ public:
|
||||
nopens=nfaceverts=0; fc1=fc2=NULL; colour[0]=colour[1]=colour[2]=colour[3]=1;
|
||||
}
|
||||
~_dwobj() {/*delete verts; delete faces;delete openings;*/
|
||||
delete fc1;delete fc2;
|
||||
delete [] fc1;delete [] fc2;
|
||||
}
|
||||
int readOpenings(FILE *fp, const int nexpected)
|
||||
{ // read up to nexpected openings, each opening may have a number of vertices
|
||||
|
Loading…
Reference in New Issue
Block a user