bugKawa - Bugs: bug #22665, Format closes OutputStream

 
 

bug #22665: Format closes OutputStream

Submitted by:  Helmut Eller <ellerh>
Submitted on:  Tue 18 Mar 2008 10:17:34 PM UTC  
 
Category: Scheme librarySeverity: 3 - Normal
Item Group: Unexpected resultStatus: Fixed
Privacy: PublicAssigned to: Per Bothner <bothner>
Open/Closed: Closed

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Sun 23 Mar 2008 07:43:00 PM UTC, comment #1:

Oops. Indeed, calling close is wrong. I added new methods 'closeThis' to only "close" the temporary OutPort.

Per Bothner <bothner>
Project AdministratorIn charge of this item.
Tue 18 Mar 2008 10:17:34 PM UTC, original submission:

The following code:

(let* ((sw (<java.io.StringWriter>))
(pw (<java.io.PrintWriter> sw)))
(format pw "foo")
(format pw "bar")
(pw:flush)
(sw:flush)
(sw:toString))

returns "foo". It should probably be "foobar" or raise
an error.

The problem seems to that Format.format$V closes port_arg.

Helmut Eller <ellerh>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by bothner (Posted a comment)
  • -unavailable- added by ellerh (Submitted the item)
  • -unavailable- added by ellerh
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 4 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sun 23 Mar 2008 07:43:00 PM UTCbothnerStatusNone=>Fixed
      Assigned toNone=>bothner
      Open/ClosedOpen=>Closed
    Tue 18 Mar 2008 10:17:34 PM UTCellerhCarbon-Copy-=>Added ellerh

    Back to the top


    Powered by Savane 3.1-cleanup1