closing files...



Hi,

I am having a problem in understanding
how to close files in maxima.

I managed to write some data into a file
by:
"
with_stdout("./soluzione.cnf",
             for i : 1 thru length(solution) do
               print(solution[i])
             ),
"
after that I don't know whether the file
is really closed but I adding after that 
"close("./soluzione.cnf")" 
does not help.

Then I read the file by:
 f: ?open(?"./soluzione.cnf"),
and I close it by 
"close(f)", which works 
but then, the next time I try to rewrite the file
I get the following error message:
"
Maxima encountered a Lisp error:

 OPEN: #<INPUT BUFFERED FILE-STREAM CHARACTER #P"./soluzione.cnf" @8> 
already points to file "/net/data/home/caruso/polly/orig/soluzione.cnf", 
opening the file again for :OUTPUT may produce unexpected results

Automatically continuing.
To reenable the Lisp debugger set *debugger-hook* to nil.
"

What should I do to solve this problem?
I guess that there must be a better way to do
what I'm doing.

  Fabrizio