unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
* Problem with truncated string ports
@ 2013-06-21 13:44 Brent Pinkney
  2013-06-21 13:52 ` Eli Zaretskii
  0 siblings, 1 reply; 6+ messages in thread
From: Brent Pinkney @ 2013-06-21 13:44 UTC (permalink / raw)
  To: guile-user

Hi,

We are using guile on Solaris 10u10 on x86 hardware and are experiencing 
odd behaviour with (format #f "~s" foo), where foo is
     1. a string containing #\" quotation characters,
     2. ~9000 bytes long.

The faulty behaviour is that the resulting string is truncated to 4096 
bytes every time.
However, the problem does not occur in the guile REPL, nor in any guise 
on Solaris SPARC or Linux x86.


Further investigation using string ports and write confirms that the 
problem can be reproduced with

     (define s (make-string 9000 #\"))
     (define o (open-output-string))
     (write s o)
     (define r (get-output-string o))
     (string-length r)                                    ; answers 4096


I have inspected the strings.c implementation but nothing obvious 
suggests why the output string is truncated to 4096 bytes.


Can anyone assist ?

Thanks,

Brent




^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2013-06-21 20:03 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-06-21 13:44 Problem with truncated string ports Brent Pinkney
2013-06-21 13:52 ` Eli Zaretskii
2013-06-21 14:15   ` Problem with truncated string ports - more info Brent Pinkney
2013-06-21 15:25     ` Mike Gran
2013-06-21 20:03     ` Mark H Weaver
     [not found]   ` <51C45F72.3030101@ffroot.co.za>
2013-06-21 15:23     ` Problem with truncated string ports - resolution Brent Pinkney

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).