Remove unnecessary null pointer checks
This commit is contained in:
parent
cb39db0b02
commit
cabf923484
8 changed files with 10 additions and 19 deletions
|
|
@ -217,8 +217,8 @@ b2Polygon::b2Polygon(b2Triangle& t) {
|
|||
void b2Polygon::Set(const b2Polygon& p) {
|
||||
if (nVertices != p.nVertices){
|
||||
nVertices = p.nVertices;
|
||||
if (x) delete[] x;
|
||||
if (y) delete[] y;
|
||||
delete[] x;
|
||||
delete[] y;
|
||||
x = new float32[nVertices];
|
||||
y = new float32[nVertices];
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue