Re: Using fork() in a GTK C/Vala application

2015-09-01 Thread Jim Charlton
On 15-09-01 07:27 AM, rastersoft wrote: In fact, I'm already using pipes and more; I can just replace the Thread call with a fork() and everything will work fine. The only idea I see I can use is to physically separate both process in different binaries and use named pipes... On 01/09/15 16:05,

Re: Using fork() in a GTK C/Vala application

2015-09-01 Thread Leandro A. F. Pereira
On Tue, Sep 1, 2015 at 10:33 AM, rastersoft wrote: > It is very subtle, because it hapens usually > after being running for two-three days. It is a double free. I tried > with Valgrind, but when I use it, the error doesn't trigger, which makes > me suspect it is a race condition between both thre

Re: Using fork() in a GTK C/Vala application

2015-09-01 Thread rastersoft
In fact, I'm already using pipes and more; I can just replace the Thread call with a fork() and everything will work fine. The only idea I see I can use is to physically separate both process in different binaries and use named pipes... On 01/09/15 16:05, Chris Vine wrote: > On Tue, 1 Sep 2015 15:

Re: Using fork() in a GTK C/Vala application

2015-09-01 Thread Chris Vine
On Tue, 1 Sep 2015 15:33:19 +0200 rastersoft wrote: > Thanks for your answer. Unfortunately, I'm running out of options: > currently I'm using threads, but there is a nasty bug that makes my > program crash sometimes. It is very subtle, because it hapens usually > after being running for two-three

Re: Using fork() in a GTK C/Vala application

2015-09-01 Thread rastersoft
Thanks for your answer. Unfortunately, I'm running out of options: currently I'm using threads, but there is a nasty bug that makes my program crash sometimes. It is very subtle, because it hapens usually after being running for two-three days. It is a double free. I tried with Valgrind, but when I

Re: Using fork() in a GTK C/Vala application

2015-09-01 Thread Chris Vine
On Tue, 1 Sep 2015 13:54:34 +0200 rastersoft wrote: > Hi all: > > I'm working on a project which, for several reasons, will use the > Posix fork() call. The question is: if I have an active GTK main loop > in the program before calling fork(), is there something I have to do > after calling it in

Using fork() in a GTK C/Vala application

2015-09-01 Thread rastersoft
Hi all: I'm working on a project which, for several reasons, will use the Posix fork() call. The question is: if I have an active GTK main loop in the program before calling fork(), is there something I have to do after calling it in the child process? I know that I must NOT use Gtk calls in the c

Wait for action activation on notification click

2015-09-01 Thread Ondrej Slamecka
Hi, I am trying to create an application (running in background, no GUI) which would display a notification and then perform an action when the notification is clicked. My code (link below) creates a notification, prepares the action and then runs the main loop -- I want it to wait for the 'app