Subject: Strange output error

From: [email-masked]
Date: Mon, 16 Jan 1995 16:02:48 +0000

I'm not sure if this is a Lisp error or an implementation error.

I have a function that reads a string from the keyboard which
has an optional parameter giving a prompt message.

This seems to work fine when called individually but in a sequence
of 3 or more calls it starts to display part of the prompt twice,
e.g.
> (read-unix-error 'filestore)
Enter application name> xfig
Enter the environment> csh
Enter error message> who
Enter problem description> 
blem description> d
Enter machine name> 
blem description> Enter machine name> d

(The 'Enter the environment>' is a separate function to read in a check
for a defined type)

The function definition is:

	(defun read-string (&optional (prompt "> "))
        	(fresh-line)
        	(format t "~a"  prompt)
        	(read-line)
	)

Does anyone have any idea why this is happening? I have to admit to not
being all that familiar with Common Lisp I/O so I may have made a
glaringly obvious error!

Thanks for any help,

David.

-- 
-=- -=- -=- -=- -=- -=- -=- -=- -=- -=- -=- -=- -=- -=- -=-
David Arnold                             ([email-masked])
Dept. Computer Science                   +44 (0)970-622449
University of Wales,Aberystwyth, Dyfed SY23 3DB, UK.
http://www.dcs.aber.ac.uk/~daa93
GCS -d+ p c++@ !l e++ m+++(*) s+/- n+ h(-) f !g w- t+@ y? 
-=- -=- -=- -=- -=- -=- -=- -=- -=- -=- -= -=- -=-- -=- -=-

---

From: haible (Bruno Haible)
Date: Mon, 16 Jan 95 17:17:00 +0100

> of 3 or more calls it starts to display part of the prompt twice,

This is a bug in CLISP which is fixed since the 1994-06-22 release.

                    Bruno Haible
                    [email-masked]

---

From: [email-masked]
Date: Tue, 31 Jan 1995 14:52:54 +0000

On Jan 16,  5:21pm, you wrote:
> Subject: Re: Strange output error
>-- End of excerpt from Bruno Haible

Hi Bruno,
   The problem is, I am forced to work with an old version of CLISP
because I have a compiled toolkit and I do not have access to the
source code. Since this is a commercial product I do not have any
influence over their recompiling for a newer version, although I have
requested it!

Is it possible to mail me the part of the CLISP source that needs to
be updated, I can then recompile it and put a smile back on my
supervisor's face :-)

Thank you,

David.

---

From: haible (Bruno Haible)
Date: Tue, 31 Jan 95 16:58:20 +0100

> source code.

You just need to look in the /pub/lisp/clisp/source-haible/1994-06-22/
directory. It contains the patches that led to that clisp version. In your
case, it is the file clispsrc-1994-01-08-to-1994-06-22.tar.z, which contains
a file diffs-1994-01-08-to-1994-06-22, and all you need of it is the patch
to stream.d, lines *** 3437,3444 **** --> --- 3449,3458 ----.

                    Bruno Haible