Re: ksh - issue with (non-existing) jobs

Liste des GroupesRevenir à cu shell 
Sujet : Re: ksh - issue with (non-existing) jobs
De : janis_papanagnou+ng (at) *nospam* hotmail.com (Janis Papanagnou)
Groupes : comp.unix.shell
Date : 26. Jan 2025, 13:13:37
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <vn58ti$3o8mi$1@dont-email.me>
References : 1 2 3 4
User-Agent : Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0
On 26.01.2025 03:17, Lawrence D'Oliveiro wrote:
On Sun, 26 Jan 2025 01:25:22 +0100, Janis Papanagnou wrote:
 
I'd guess, though, that it wouldn't have helped ...
 
Well, if you explicitly waited for a job it couldn’t find, then you would
be right. But given it is capable of waiting in general for any job to
terminate,

Not sure what you mean here.

You initiate jobs, say, by something like 'a_command &', the command
gets registered in a shell table. And at any time you can 'wait' for
it. The job information (with its actual execution state) is at least
as long in the job table until a <Enter> is hit, since the information
e.g. about termination must be created.

it might take a different path through the code that is not
afflicted by the same state confusion.

Yes, that can of course be the case - I haven't inspected the source.

My guess is based just on the typical software architectures. Usually
you have one place to maintain the jobs, a [shell internal] job table,
and functions to check existence (registration) and get any required
attributes for any shell command that works with the registered shell
jobs. So if the respective shell commands see arguments like %1 they
would certainly look up those jobs and its attributes in that table
with that key. It's most likely that 'kill %1' and 'wait %1' would
both do such a table lookup, certainly _before_ they take the actions
on the identified job.

If you have another scenario in mind, please elaborate.

Janis


Date Sujet#  Auteur
25 Jan 25 * ksh - issue with (non-existing) jobs8Janis Papanagnou
26 Jan 25 `* Re: ksh - issue with (non-existing) jobs7Lawrence D'Oliveiro
26 Jan 25  `* Re: ksh - issue with (non-existing) jobs6Janis Papanagnou
26 Jan 25   `* Re: ksh - issue with (non-existing) jobs5Lawrence D'Oliveiro
26 Jan 25    `* Re: ksh - issue with (non-existing) jobs4Janis Papanagnou
26 Jan 25     `* Re: ksh - issue with (non-existing) jobs3Lawrence D'Oliveiro
26 Jan 25      `* Re: ksh - issue with (non-existing) jobs2Janis Papanagnou
27 Jan 25       `- Re: ksh - issue with (non-existing) jobs1Lawrence D'Oliveiro

Haut de la page

Les messages affichés proviennent d'usenet.

NewsPortal