Commit d1e8b34
Multiprocess mode: using direct assignment for writing into mmap (#315)
Using pack_into can create atomicity problems when writing on cpython, setting the bytes to 0 before writing the value.
When having a lot of writes, some reads would return 0 instead of the real value.
Signed-off-by: David Guerrero <heldroe@gmail.com>1 parent c0cee96 commit d1e8b34
1 file changed
Lines changed: 13 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
33 | | - | |
34 | | - | |
| 33 | + | |
| 34 | + | |
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
| |||
493 | 493 | | |
494 | 494 | | |
495 | 495 | | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
| 502 | + | |
| 503 | + | |
| 504 | + | |
| 505 | + | |
| 506 | + | |
496 | 507 | | |
497 | 508 | | |
498 | 509 | | |
| |||
0 commit comments