- Subject: Re: [slang-users] Send a signal to a running process?
- From: jed@xxxxxxxxxxx (John E. Davis)
- Date: Sun, 27 Mar 2016 23:56:25 -0400
Morten Bo Johansen <mbj@xxxxxxxxxxx> wrote:
> So the question is, how can I send a SIGHUP to the instance of mupdf
> that is associated with the jed buffer when pressing the key to update
> the display?
[...]
> ifnot (__is_initialized (&pdfviewer_pid))
> {
> pdfviewer_pid = open_process ("mupdf", pdf_file, 1);
> set_process (pdfviewer_pid, "output", &show_pdfviewer_error);
> set_process (pdfviewer_pid, "signal", &pdfviewer_signal_handler);
> process_query_at_exit (pdfviewer_pid, 0);
> }
> else
> % this is of course not tenable, but illustrates what I want
> () = system ("kill -hup $(pidof /usr/lib/mupdf/mupdf-x11)");
Try: signal_process (pdfviewer_pid, 1);
Here, 1 is SIGHUP. I see that the SIG* constants were not made
available for jed. I will add that to my TODO list.
Thanks,
--John
_______________________________________________
For list information, visit <http://jedsoft.org/slang/mailinglists.html>.
[2016 date index]
[2016 thread index]
[Thread Prev] [Thread Next]
[Date Prev] [Date Next]