[CDRIVER-1881] 2 memory leaks in mongoc_collection_create_index_with_opts() Created: 24/Oct/16  Updated: 25/Oct/16  Resolved: 25/Oct/16

Status: Closed
Project: C Driver
Component/s: None
Affects Version/s: 1.5.0
Fix Version/s: 1.5.0

Type: Bug Priority: Major - P3
Reporter: Hannes Magnusson Assignee: Hannes Magnusson
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

==21784== 8 bytes in 1 blocks are definitely lost in loss record 1 of 611
==21784==    at 0x4C2FD5F: realloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==21784==    by 0x4E5B328: bson_realloc (bson-memory.c:150)
==21784==    by 0x4E5D2EF: bson_string_append (bson-string.c:156)
==21784==    by 0x4E5D6BE: bson_string_append_printf (bson-string.c:269)
==21784==    by 0x49060D: mongoc_collection_keys_to_index_string (mongoc-collection.c:990)
==21784==    by 0x490DE4: mongoc_collection_create_index_with_opts (mongoc-collection.c:1180)
==21784==    by 0x435BFD: test_index_w_write_concern (test-mongoc-collection.c:1740)
==21784==    by 0x479FF6: TestSuite_AddHelper (TestSuite.c:333)
==21784==    by 0x47A653: TestSuite_RunTest (TestSuite.c:602)
==21784==    by 0x47B0DF: TestSuite_RunNamed (TestSuite.c:911)
==21784==    by 0x47B21F: TestSuite_Run (TestSuite.c:947)
==21784==    by 0x415A53: main (test-libmongoc.c:1844)
==21784== 
==21784== 128 bytes in 1 blocks are definitely lost in loss record 555 of 611
==21784==    at 0x4C2DB8F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==21784==    by 0x4E5B263: bson_malloc (bson-memory.c:68)
==21784==    by 0x4E48626: _bson_impl_inline_grow (bson.c:118)
==21784==    by 0x4E487D9: _bson_grow (bson.c:206)
==21784==    by 0x4E48EFD: _bson_append_bson_begin (bson.c:452)
==21784==    by 0x4E4932F: bson_append_array_begin (bson.c:586)
==21784==    by 0x490EA9: mongoc_collection_create_index_with_opts (mongoc-collection.c:1198)
==21784==    by 0x435BFD: test_index_w_write_concern (test-mongoc-collection.c:1740)
==21784==    by 0x479FF6: TestSuite_AddHelper (TestSuite.c:333)
==21784==    by 0x47A653: TestSuite_RunTest (TestSuite.c:602)
==21784==    by 0x47B0DF: TestSuite_RunNamed (TestSuite.c:911)
==21784==    by 0x47B21F: TestSuite_Run (TestSuite.c:947)
==21784== 



 Comments   
Comment by Githook User [ 25/Oct/16 ]

Author:

{u'username': u'bjori', u'name': u'Hannes Magnusson', u'email': u'bjori@php.net'}

Message: CDRIVER-1881 2 memory leaks in mongoc_collection_create_index_with_opts
Branch: master
https://github.com/mongodb/mongo-c-driver/commit/5eddde2f43c10731e4f11cf869c22f7dcc07df76

Generated at Wed Feb 07 21:13:30 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.