Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Call <code>XInitThreads()</code>. This should be done before <code>gtk_init</code>, that will stop the messages!</p> <p>Something like this:</p> <pre><code> #include &lt;X11/Xlib.h&gt; ... XInitThreads(); ... gtk_init(&amp;argc, &amp;argv); </code></pre> <p>I don't remember seeing these messages before GLIB 2.32, when <code>g_thread_init()</code>/<code>gdk_threads_init()</code> were used.</p> <p>You might want to check out <code>g_thread_pool_new</code> and <code>g_thread_pool_push</code>. From thread, use <code>g_main_context_invoke</code> to execute in main loop or just wrap thread between <code>gdk_threads_enter()</code>/<code>gdk_threads_leave()</code></p> <p>I do not use a tray so I can not easily check this. I think you are correct about gdk_threads_add_idle using locks to protect GTK/GDK API. There is nothing obvious to me that would cause these messages to appear. The function description for gtk_status_icon_new_from_icon_name states that "If the current icon theme is changed, the icon will be updated appropriately. Which to me, implies your code is not the only code that will access the X display, which could potentially be the problem.</p> <p>There is also some related info regarding XInitThreads() at</p> <p><a href="https://stackoverflow.com/questions/13351297/what-is-the-downside-of-xinitthreads">What is the downside of XInitThreads()?</a></p> <p>Note that while GDK uses locks for the display, GTK/GDK do not ever call XInitThreads.</p> <p>On a side note: What's protecting the global variable "onclick", which is passed to execl after a fork(), The child will not inherit the parent's memory locks, and GLib mainloop is incompatible with fork(). Maybe you could copy the string to local variable.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload