POV-Ray : Newsgroups : povray.general : Bug in beta 6 and file reading? Server Time
13 Aug 2024 09:34:20 EDT (-0400)
  Bug in beta 6 and file reading? (Message 1 to 2 of 2)  
From: Friedemann Schmidt
Subject: Bug in beta 6 and file reading?
Date: 16 Sep 1998 11:25:39
Message: <35ffca67.11014728@news.povray.org>
Hi,

the following code

  #fopen File "test.dat" write
  #declare i = 0;
  #while (i < 10)
    #write (File, i, ",")
    #declare i = i + 1;
  #end
  #fclose File

  #fopen File "test.dat" read
  #while (defined(File))
    #read(File, j)
    #debug concat(str(j, 0, 0), " ")
  #end
  #debug "finished"
  #fclose File

writes the digits 0..9 to a file, delimited by a comma. Then it should
reread them from the file into "j". It produces the output:

  0 1 2 3 4 5 6 7 8 9 9 finished

instead of

  0 1 2 3 4 5 6 7 8 9 finished

without the last "9".

It seems to be a bug, isn't ist?

Bye,
Friedemann



Friedemann Schmidt
F.S### [at] fhtw-berlinde
Raytracing-Gallery: http://www.rz.fhtw-berlin.de/~s0049669/


Post a reply to this message

From: Thorsten Froehlich
Subject: Re: Bug in beta 6 and file reading?
Date: 16 Sep 1998 12:00:17
Message: <35ffd281.0@news.povray.org>
In article <35ffca67.11014728@news.povray.org> , F.S### [at] fhtw-berlinde (Friedemann
Schmidt) wrote:

>Hi,
>
>the following code
>
>  #fopen File "test.dat" write
>  #declare i = 0;
>  #while (i < 10)
>    #write (File, i, ",")
>    #declare i = i + 1;
>  #end
>  #fclose File
>
>  #fopen File "test.dat" read
>  #while (defined(File))
>    #read(File, j)
>    #debug concat(str(j, 0, 0), " ")
>  #end
>  #debug "finished"
>  #fclose File
>
>writes the digits 0..9 to a file, delimited by a comma. Then it should
>reread them from the file into "j". It produces the output:
>
>  0 1 2 3 4 5 6 7 8 9 9 finished
>
>instead of
>
>  0 1 2 3 4 5 6 7 8 9 finished
>
>without the last "9".
>
>It seems to be a bug, isn't ist?
>
>Bye,
>Friedemann
>
>
>
>Friedemann Schmidt
>F.S### [at] fhtw-berlinde
>Raytracing-Gallery: http://www.rz.fhtw-berlin.de/~s0049669/


I hope you have send this to the official bug reporting e-mail address as well.
However, I will forward it in cas you did not.


Thorsten

____________________________________________________
Thorsten Froehlich, Duisburg, Germany


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.