summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: fc5c43d)
raw | patch | inline | side by side (parent: fc5c43d)
author | Chris Lundquist <clundquist@bluebox.net> | |
Mon, 30 Jan 2012 21:49:32 +0000 (13:49 -0800) | ||
committer | Chris Lundquist <clundquist@bluebox.net> | |
Mon, 30 Jan 2012 21:49:32 +0000 (13:49 -0800) |
src/write_mongodb.c | patch | blob | history |
diff --git a/src/write_mongodb.c b/src/write_mongodb.c
index 704ac0710382af0ed994b7b035a295f8200f3044..4deb24d30979c748c546eaed464fb01113814fdc 100644 (file)
--- a/src/write_mongodb.c
+++ b/src/write_mongodb.c
else
assert (23 == 42);
}
+ /* We must finish the record, other wise the insert will fail */
bson_finish(&record);
pthread_mutex_lock (&node->lock);
}
pthread_mutex_unlock (&node->lock);
+ /* free our resource as not to leak memory */
+ bson_destroy(&record);
return (0);
} /* }}} int wm_write */