Commit 7fc3903
committed
CDRIVER-2693 segfault in bson_b64_pton
The function relies on data that is initialized by mongoc_init, but a
libbson-only application never calls mongoc_init. Use pthread_once to
initialize the data on demand instead.1 parent 084c879 commit 7fc3903
File tree
4 files changed
+32
-10
lines changed- src
- common
- libmongoc/src/mongoc
4 files changed
+32
-10
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
1 | 6 | | |
2 | 7 | | |
3 | 8 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | 33 | | |
37 | 34 | | |
38 | 35 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
| 43 | + | |
43 | 44 | | |
44 | 45 | | |
45 | 46 | | |
| |||
258 | 259 | | |
259 | 260 | | |
260 | 261 | | |
261 | | - | |
262 | | - | |
263 | | - | |
264 | | - | |
265 | | - | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
266 | 282 | | |
267 | 283 | | |
268 | 284 | | |
| |||
286 | 302 | | |
287 | 303 | | |
288 | 304 | | |
| 305 | + | |
| 306 | + | |
289 | 307 | | |
290 | 308 | | |
291 | 309 | | |
| |||
501 | 519 | | |
502 | 520 | | |
503 | 521 | | |
| 522 | + | |
| 523 | + | |
| 524 | + | |
| 525 | + | |
504 | 526 | | |
505 | 527 | | |
506 | 528 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
91 | 91 | | |
92 | 92 | | |
93 | 93 | | |
94 | | - | |
95 | | - | |
96 | 94 | | |
97 | 95 | | |
98 | 96 | | |
| |||
0 commit comments