mirror of https://github.com/YosysHQ/abc.git
Fix destructor rewireMiaig.h
Pointers that are allocated with a C-style malloc should be deleted with free -- not with the C++-style delete. Using delete here will trip up toolchains that enforce using free for memory allocated with malloc.
This commit is contained in:
parent
64637b8395
commit
e7c304d3d1
|
|
@ -441,7 +441,7 @@ inline void Miaig::release(void) {
|
||||||
if (_data->pRequire) free(_data->pRequire);
|
if (_data->pRequire) free(_data->pRequire);
|
||||||
if (_data->pTable) free(_data->pTable);
|
if (_data->pTable) free(_data->pTable);
|
||||||
if (_data->pNtkMapped) Vi_Free(_data->pNtkMapped);
|
if (_data->pNtkMapped) Vi_Free(_data->pNtkMapped);
|
||||||
delete _data;
|
free(_data);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -612,4 +612,4 @@ inline void Miaig::attachTiming(vi *vCiArrs, vi *vCoReqs) {
|
||||||
ABC_NAMESPACE_CXX_HEADER_END
|
ABC_NAMESPACE_CXX_HEADER_END
|
||||||
#endif // RW_ABC
|
#endif // RW_ABC
|
||||||
|
|
||||||
#endif // REWIRE_MIAIG_H
|
#endif // REWIRE_MIAIG_H
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue