diff options
author | om <om@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-07-23 10:55:19 +0000 |
---|---|---|
committer | om <om@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-07-23 10:55:19 +0000 |
commit | 5c8937a751101bd52b406f3d72b20cd47f001c95 (patch) | |
tree | 2e549573a214ce0d4cda2f2fcf48d8a2a9fe68f4 /src/modules | |
parent | 9309ce59d33605c15ad54c1a120e87fa191f7de3 (diff) |
Free, as they should be, fieldlist and/or fieldmap in destructor of PgSQLresult *if* they were allocated
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4525 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/extra/m_pgsql.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/modules/extra/m_pgsql.cpp b/src/modules/extra/m_pgsql.cpp index 7b452e7c6..ec44f2970 100644 --- a/src/modules/extra/m_pgsql.cpp +++ b/src/modules/extra/m_pgsql.cpp @@ -223,6 +223,13 @@ public: ~PgSQLresult() { + /* If we allocated these, free them... */ + if(fieldlist) + DELETE(fieldlist); + + if(fieldmap) + DELETE(fieldmap); + PQclear(res); } |