doubt about GFileMonitor

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

 



Hello,

    I am having some trouble when using GFileMonitor (GIO) with more
than 1 process.
    Here is what I do:

1 - I create a GFileMonitor to monitor a directory, using the function
g_file_monitor_directory
2 - I connect to the changed signal
3 - it works correctly when I have one single process
4 - I fork() my process
5 - in my child process, I free the monitor by using g_object_unref,
but in the parent process the monitor is still there
6 - my "changed" signal callback stops being called on file events.

    Does someone know why this happens? Is this expected to be like
this? I looked at the documentation and it says there:
"The signal will be emitted in the thread-default main context of the
thread that the monitor was created in (though if the global default
main context is blocked, this may cause notifications to be blocked
even if the thread-default context is still running"

    But it is still unclear to me, because I created another process
and not another thread.

Thanks in advance.
Regards,
--
Marcelo Elias Del Valle
http://mvalle.com
_______________________________________________
gtk-list mailing list
gtk-list@xxxxxxxxx
http://mail.gnome.org/mailman/listinfo/gtk-list



[Index of Archives]     [Touch Screen Library]     [GIMP Users]     [Gnome]     [KDE]     [Yosemite News]     [Steve's Art]

  Powered by Linux