TADS Bug Database

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0000065TADS 3Interpreterpublic2009-06-04 17:152009-06-04 17:25
ReporterMichael Roberts 
Assigned ToMichael Roberts 
PlatformIntelOSWindowsOS VersionXP
Summary0000065: File.writeFile() in text mode writes wrong output for strings with embedded newlines
DescriptionIf a string is written to a file with File.writeFile() in text mode, and the string contains embedded newlines (\n characters), the generated file contains incorrect data.
Steps To ReproduceCompile and run:

#include <file.h>
  local f = File.openTextFile('foo', FileAccessWrite, 'ASCII');
  f.writeFile('Line 1\nLine 2\nLine 3\n');

The resulting file will not contain the correct text.
Additional InformationThis is due to the fix in 3.0.18 for newline translation writing UTF-16 files. The fix got the newline translation right, but failed to deal properly with any additional text in the same string after a newline.
TagsNo tags attached.
Fixed In Version3.0.19
Attached Files

- Relationships
related to 0000064resolvedMichael Roberts Corrupt output for mkweb.t 

-  Notes
There are no notes attached to this issue.

- Issue History
Date Modified Username Field Change
2009-06-04 17:15 Michael Roberts New Issue
2009-06-04 17:15 Michael Roberts Status new => assigned
2009-06-04 17:15 Michael Roberts Assigned To => Michael Roberts
2009-06-04 17:23 Michael Roberts Relationship added related to 0000064
2009-06-04 17:25 Michael Roberts Fixed In Version => 3.0.19
2009-06-04 17:25 Michael Roberts Status assigned => resolved
2009-06-04 17:25 Michael Roberts Resolution open => fixed

Copyright © 2000 - 2018 MantisBT Team
Powered by Mantis Bugtracker