Commit 9f6496b9 by Konstantin Käfer

delete field objects as early as possible

parent 4162bcb0
...@@ -297,6 +297,8 @@ bool Statement::Bind(const Data::Parameters parameters) { ...@@ -297,6 +297,8 @@ bool Statement::Bind(const Data::Parameters parameters) {
status = sqlite3_bind_null(handle, pos); status = sqlite3_bind_null(handle, pos);
} break; } break;
} }
DELETE_FIELD(field);
} }
if (status != SQLITE_OK) { if (status != SQLITE_OK) {
......
...@@ -89,11 +89,6 @@ public: ...@@ -89,11 +89,6 @@ public:
callback = Persistent<Function>::New(cb_); callback = Persistent<Function>::New(cb_);
} }
~Baton() { ~Baton() {
Data::Parameters::const_iterator it = parameters.begin();
Data::Parameters::const_iterator end = parameters.end();
for (; it < end; it++) {
DELETE_FIELD(*it);
}
stmt->Unref(); stmt->Unref();
ev_unref(EV_DEFAULT_UC); ev_unref(EV_DEFAULT_UC);
callback.Dispose(); callback.Dispose();
......
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