Hi Dmitrij,
> Apparently I have similar problem with surf:
You could try to workaround by launching surf with:
$ LD_PRELOAD=/usr/local/lib/gio/modules/libgiognutls.so surf
For vimb, it works.
About the problem, my last "minimal c-file" looks like:
/*
* cc test.c -o test `pkg-config -cflags -libs glib-2.0 gio-2.0`
*/
#include <stdio.h>
#include <stdlib.h>
#include <glib.h>
#include <gio/gio.h>
int main(int argc, char *argv) {
//g_module_open("/usr/local/lib/gio/modules/libgiognutls.so",
G_MODULE_BIND_MASK);
g_tls_backend_get_default ();
fork();
return(EXIT_SUCCESS);
}
The g_module_open function is called near the pthread_atfork in
g_tls_backend_get_default.
But:
- only with it (g_module_open + fork): no problem
- with g_module_open+g_tls_backend_get_default+fork: no problem
So there is something between the two...
the g_module_open (in g_tls_backend_get_default) will call:
_g_module_open (file_name=0x15887c4669c0
"/usr/local/lib/gio/modules/libgiognutls.so", bind_lazy=1, bind_local=1) at
gmodule-dl.c:97
which call dlopen().
the pthread_atfork seems (but not sure) to be part of dlopen in the
pthread case.
--
Sébastien Marie