[bug] (command-line nil) ?

Q&A's, tips, howto's
Locked
newdep
Posts: 2038
Joined: Mon Feb 23, 2004 7:40 pm
Location: Netherlands

[bug] (command-line nil) ?

Post by newdep »

Hi Lutz,

newlisp 9.3.8

>(command-line nil)
results in a 100% cpu load under linux
-- (define? (Cornflakes))

Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

Post by Lutz »

A program disabling the command line should never get there, but sit in a 'read-line' or other I/O statement waiting for input. If on the toplevel as last statement, it will basically hang in an empty loop. I inserted a sleep for this situation in tomorrows development release.

For a program using (command-line nil) the best would be to have an (exit) statement at the end of the file.

newdep
Posts: 2038
Joined: Mon Feb 23, 2004 7:40 pm
Location: Netherlands

Post by newdep »

aaaaa i remember now, ive asked this befor... Sorry ;-)
-- (define? (Cornflakes))

Locked