Re: terminating clisp: clisp.exe vs lisp.exe

"Pascal J. Bourguignon" <[email protected]>
Newsgroups gmane.lisp.clisp.devel
Organization InformatiMago.
Message-ID <[email protected]>
Sam Steingold <[email protected]> writes:

>> * Pascal J. Bourguignon <[email protected]> [2012-06-08 12:58:38 +0200]:
>>
>> Perhaps it would be a good idea to remove the call to fork() from the
>> clisp driver?
>
> there is no fork() there.
> unix uses execv(), windows uses CreateProcess().

Indeed.  The OP report is bogus.


Anton Vodonosov <[email protected]> writes:

> Hello.
>
> My program starts clisp as a child process to do some work.
> Sometimes this work may hang.
>
> In this case I would like to kill the child lisp process.
>
> clisp.exe starts another process, lisp.exe which, as I understand,
> preforms all the job.
>
> It's not trivial to even get process id of lisp.exe.

It is trivial to get the process id of a child process.  You just get it
as result of fork(2) (or CreateProcess()).  In bash(2), this child
process PID is returned by the special variable $!:

    clisp -norc -q -ansi \
        -x '(format t "~%clisp pid=~A~2%" (process-id))' & \
        echo "bash pid=$!"


> What are my options to reliable kill started CLISP?

Memorize the child PID, and use it to send a signal.


> Is it possible to start CLISP in a way that it consists only of one process?

It consists only of one process.




-- 
__Pascal Bourguignon__                     http://www.informatimago.com/
A bad day in () is better than a good day in {}.

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
clisp-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/clisp-devel
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.