Re: [patch] improve ended-job check

2016-10-26 Fir de Conversatie Ozaki Kiichi
Additionally; https://github.com/vim/vim/blob/46fceaa/runtime/doc/channel.txt#L601 > Vim checks about every 10 seconds for jobs that ended. Maybe we can drop this line :) -- -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below the text you are

Re: [patch] improve ended-job check

2016-10-22 Fir de Conversatie Ozaki Kiichi
There is another problem on unix environment: When a job is unreferenced, detection of job-completed is delayed. [repro steps] test.vim fu! ExitCb(job, status) echom 'exited' reltimestr(reltime(s:elapsed)) endfu let s:elapsed = reltime() call job_start('sleep 1', {'exit_cb': 'ExitCb'})

Re: [patch] improve ended-job check

2016-10-15 Fir de Conversatie Bram Moolenaar
Ozaki Kiichi wrote: > I updated patch. > > - remove JOB_WAITED > - separate job_cleanup process from job_status > - get off jv_status check from job_still_useful, and new job_still_alive > checks > jv_status and job_still_useful (i.e. job_still_alive is original > job_still_useful) Thanks!

Re: [patch] improve ended-job check

2016-10-15 Fir de Conversatie Ozaki Kiichi
I updated patch. - remove JOB_WAITED - separate job_cleanup process from job_status - get off jv_status check from job_still_useful, and new job_still_alive checks jv_status and job_still_useful (i.e. job_still_alive is original job_still_useful) > Does that fix #1155? Unfortunately not. But

Re: [patch] improve ended-job check

2016-10-14 Fir de Conversatie LCD 47
On 14 October 2016, Bram Moolenaar wrote: > > Ozaki Kiichi wrote: > > > Currently, vim checks ended-job every 10 second; thus exit_cb is delayed > > 10 seconds at the maximum. > > > > I propose the following: > > > >

Re: [patch] improve ended-job check

2016-10-14 Fir de Conversatie Bram Moolenaar
Ozaki Kiichi wrote: > Currently, vim checks ended-job every 10 second; thus exit_cb is delayed > 10 seconds at the maximum. > > I propose the following: > > https://gist.github.com/ichizok/fe9743f46822a9015ed2f7d65238c5db > > os_unix: check by waitpid(-1, _, WNOHANG). > os_win32: check by

Re: [patch] improve ended-job check

2016-10-14 Fir de Conversatie Christian Brabandt
Hi Ozaki! On Fr, 14 Okt 2016, Ozaki Kiichi wrote: > Hi. > > Currently, vim checks ended-job every 10 second; thus exit_cb is delayed > 10 seconds at the maximum. > > I propose the following: > > https://gist.github.com/ichizok/fe9743f46822a9015ed2f7d65238c5db > > os_unix: check by

[patch] improve ended-job check

2016-10-14 Fir de Conversatie Ozaki Kiichi
Hi. Currently, vim checks ended-job every 10 second; thus exit_cb is delayed 10 seconds at the maximum. I propose the following: https://gist.github.com/ichizok/fe9743f46822a9015ed2f7d65238c5db os_unix: check by waitpid(-1, _, WNOHANG). os_win32: check by WaitForMultipleObjects(), "the number