[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: bug in prompting loops



Rick Taube <hkt@zkm.de> wrote:

> there is a stream bug in both the DOS and the NeXTStep versions of  
> CLISP that causes output in a PROMPT/READ loop to get multiply  
> printed after some number of correct occurences.

Indeed. This bug has been there for a very long time.
Please use this fix if you are in a position to recompile clisp from source.

*** stream.d.orig       Sat Jan  8 14:45:35 1994
--- stream.d    Mon May  9 21:54:16 1994
***************
*** 3437,3444 ****
        }}
        # Wenn stdin und stdout beide dasselbe Terminal sind, können
        # wir davon ausgehen, daß der Cursor in Spalte 0 steht.
!       if (eq(TheStream(stream)->strm_terminal_isatty,S(equal)))
!         { TheStream(stream)->strm_wr_ch_lpos = Fixnum_0; }
        # Nun fangen wir an, die Zeichen des Buffers zu liefern:
        goto restart_it;
      }}
--- 3437,3446 ----
        }}
        # Wenn stdin und stdout beide dasselbe Terminal sind, können
        # wir davon ausgehen, daß der Cursor in Spalte 0 steht.
!       if (eq(TheStream(*stream_)->strm_terminal_isatty,S(equal)))
!         { TheStream(*stream_)->strm_wr_ch_lpos = Fixnum_0;
!           TheArray(TheStream(*stream_)->strm_terminal_outbuff)->dims[1] = 0; # Fill-Pointer := 0
!         }
        # Nun fangen wir an, die Zeichen des Buffers zu liefern:
        goto restart_it;
      }}


                    Bruno Haible
                    haible@ma2s2.mathematik.uni-karlsruhe.de