delorie.com/archives/browse.cgi | search |
From: | Martin Ambuhl <mambuhl AT earthlink DOT net> |
Newsgroups: | comp.os.msdos.djgpp |
Subject: | Re: Program too large? |
Date: | Tue, 28 Sep 1999 23:29:07 -0400 |
References: | <Pine DOT SUN DOT 3 DOT 91 DOT 990928092947 DOT 17309E-100000 AT is> <7sqj96$kee$1 AT news8 DOT svr DOT pol DOT co DOT uk> <7sqp0b$mtb$1 AT solomon DOT cs DOT rose-hulman DOT edu> <7srlju$65r$1 AT news6 DOT svr DOT pol DOT co DOT uk> |
X-Posted-Path-Was: | not-for-mail |
X-Accept-Language: | en |
X-ELN-Date: | 29 Sep 1999 03:27:00 GMT |
X-ELN-Insert-Date: | Tue Sep 28 20:35:05 1999 |
Organization: | Nocturnal Aviation |
Lines: | 32 |
Mime-Version: | 1.0 |
NNTP-Posting-Host: | dialup-209.246.66.213.newyork2.level3.net |
Message-ID: | <37F18783.BA51E8CE@earthlink.net> |
X-Mailer: | Mozilla 4.61 [en] (Win95; U) |
To: | djgpp AT delorie DOT com |
DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
Reply-To: | djgpp AT delorie DOT com |
Tom Morton wrote: > BTW any way of avoiding warnings associated with > > sprintf(buffer, "%d", long integer); > > It reports that format should be integer and not long but works fine > with long. [Yes we know that is not your real code. Wouldn't have been as easy to use long x; sprintf(biffer,"%d", x); as your example? It would avoid an additional syntax error which is unrelated to your question.] "Works fine" is the road to damnation. Your code is wrong and needs fixing. You avoid this warning by writing correct code. The specifier for a (signed) long is "%ld". -- Martin Ambuhl mambuhl AT earthlink DOT net __________________________________________________________ Fight spam now! Get your free anti-spam service: http://www.brightmail.com
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |