home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sys.mac.programmer
- Path: sparky!uunet!darwin.sura.net!jvnc.net!princeton!phoenix.Princeton.EDU!rtbunker
- From: rtbunker@phoenix.Princeton.EDU (Ross T. Bunker)
- Subject: printf() problem in thinkC
- Message-ID: <1992Jul23.231137.27543@Princeton.EDU>
- Originator: news@ernie.Princeton.EDU
- Sender: news@Princeton.EDU (USENET News System)
- Nntp-Posting-Host: phoenix.princeton.edu
- Organization: Princeton University
- Date: Thu, 23 Jul 1992 23:11:37 GMT
- Lines: 22
-
- Hello,
- I'm having problems with printf() in ThinkC 5.02. In attempting to
- print a string > 32K, printf("%s", str) prints a lot of blanks, then the
- string followed by garbage. It does not end. This is not a problem with
- lack of a NULL terminater. Both puts, and fwrite work fine. the printf
- family of functions however fails. Has anyone else noticed this? (like many
- people print out > 32 K strings! :-) Is there a fix?
- I have tested this VERY thoroughly and I'm as sure as I can be that it
- is NOT something i'm doing incorrectly (Though everytime I say that it
- inevitably is.) It is possible that there is some subtlety that i am not
- aware of in terms size of ints and things, but I have gone in to macsbug and
- watched it pass arguments and it seems fine.
- If you haven't heard of this and want to see it for yourself I can mail
- you a short (10) line program that illustrates it.
-
- Thanks very much for any help.
-
- --
- ------------------------------------------------------------------------------
- :)ross | I don't have to take this abuse from you --
- Internet - rtbunker@princeton.edu | I've got hundreds of people waiting to abuse
- Bitnet - rtbunker@pucc.bitnet | me. --Bill Murray, "Ghostbusters"
-