Replies: 4 comments 5 replies
-
Can you provide an example? I am not sure what to comment on this. We run the tests with ASAN, so I don't believe there are dangling pointers. |
Beta Was this translation helpful? Give feedback.
-
I stopped using direct assignment (method return) and started dumping and parsing again and my problems stopped.
I used the update method to set the value.
Now as a rule I will avoid using |
Beta Was this translation helpful? Give feedback.
-
The problem has reduced a lot with the changes mentioned, but it is still happening. If you notice in the images some internal pointers of the JSON objects are invalid (0xdddddddddd) |
Beta Was this translation helpful? Give feedback.
-
The problem is caused by the use in multiple threads of a list of objects that have a JSON object as one of their attributes. I'm going to close the issue as it's probably not a library problem. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi
I use the library in a very complex application with numerous threads and json assignment operations.
I did all the mutex control to avoid competition between threads when accessing the same json object. But I'm getting lots of "access violation" at random times during execution.
Where I investigated it appears that the memory that some internal pointers of the JSON object point to has been removed. That's why I suspect that when making an assignment (operator =) the values are not set in a completely new object but rather some pointers to the data are passed on. Therefore, when removing the original object, the pointer memory is removed.
Is there any way I can do a "deep copy" to ensure everything has been duplicated and be able to test whether this solves my problem and confirms my theory?
Thanks
Beta Was this translation helpful? Give feedback.
All reactions