Commit 0043299b authored by JINMEI Tatuya's avatar JINMEI Tatuya
Browse files

removed redundant null checks before delete.

should be trivial enough, skipping review.


git-svn-id: svn://bind10.isc.org/svn/bind10/trunk@2604 e5f2f494-b856-4b98-b285-d166d9295462
parent f7d5d843
......@@ -1192,8 +1192,7 @@ Message_init(s_Message* self, PyObject* args) {
static void
Message_destroy(s_Message* self) {
if (self->message != NULL)
delete self->message;
delete self->message;
self->message = NULL;
Py_TYPE(self)->tp_free(self);
}
......
......@@ -201,8 +201,7 @@ RRClass_init(s_RRClass* self, PyObject* args) {
static void
RRClass_destroy(s_RRClass* self) {
if (self->rrclass != NULL)
delete self->rrclass;
delete self->rrclass;
self->rrclass = NULL;
Py_TYPE(self)->tp_free(self);
}
......
......@@ -199,8 +199,7 @@ RRTTL_init(s_RRTTL* self, PyObject* args) {
static void
RRTTL_destroy(s_RRTTL* self) {
if (self->rrttl != NULL)
delete self->rrttl;
delete self->rrttl;
self->rrttl = NULL;
Py_TYPE(self)->tp_free(self);
}
......
......@@ -239,8 +239,7 @@ RRType_init(s_RRType* self, PyObject* args) {
static void
RRType_destroy(s_RRType* self) {
if (self->rrtype != NULL)
delete self->rrtype;
delete self->rrtype;
self->rrtype = NULL;
Py_TYPE(self)->tp_free(self);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment