delete of NULL pointer is noop, so no need to check
Closed, InvalidPublic

Description

In C++, it is unnecessary to check for non-NULL before invoking delete:

if (foo) delete foo;

can be more simply written as

delete foo;

(Ref: section 5.3.5 of the C++98 spec, paragraph 2.)

This patch just fixes some initial cases I came across; no doubt there are others waiting to be found.

Details

Type
Bug
Lawrence D'Oliveiro (ldo) set Type to Bug.

Sorry, I should have marked this as a patch, not a bug.

Bastien Montagne (mont29) closed this task as "Invalid".May 22 2016, 6:51 PM
Bastien Montagne (mont29) claimed this task.

Thanks for the patch, be we for sure won’t touch to extern library's code - not until it’s a question of live or death for Blender! :P

Suggest you report the issue to carve team.

I see the header files refer to http://carve-csg.com/, which no longer exists.

So where is this “carve team” to be found?