Re: Thread safety of ostree_repo_pull_with_options



To those who may be interested: creating and setting default
GMainContext for every thread (g_main_context_new();
g_main_context_push_default_thread()) solves the problem.

Best,
Anton Gerasimov

On 06/14/2017 02:44 PM, Anton Gerasimov wrote:
Hi,

I'm trying to run multiple instances of ostree_repo_pull_with_options
simultaneously (against different repos) from multiple threads and
running into various segmentation faults and assertion errors (showing
reference/dereference mismatch for objects etc.). Simple inspection
showed no obvious global state, so now I try running it through Valgrind
to see what's going on.

But before I get too far I just wanted to ask if
ostree_repo_pull_with_option is actually intended to be run in a
multithreaded environment, or was it a bad idea initially?

Thanks,
Anton Gerasimov

-- 
Anton Gerasimov, ATS Advanced Telematic Systems GmbH
Kantstrasse 162, 10623 Berlin
Managing Directors: Dirk Pöschl, Armin G. Schmidt
Register Court: HRB 151501 B, Amtsgericht Charlottenburg




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]