From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id FAA25546; Tue, 30 Sep 2003 05:51:21 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id FAA24372 for ; Tue, 30 Sep 2003 05:51:20 +0200 (MET DST) Received: from herd.plethora.net (herd.plethora.net [205.166.146.1]) by nez-perce.inria.fr (8.11.1/8.11.1) with ESMTP id h8U3pJ508121 for ; Tue, 30 Sep 2003 05:51:19 +0200 (MET DST) Received: from bhurt.plethora.net (bhurt.plethora.net [205.166.146.49]) by herd.plethora.net (8.11.6/8.10.1) with ESMTP id h8U3p7C13804; Mon, 29 Sep 2003 22:51:08 -0500 (CDT) Date: Mon, 29 Sep 2003 22:56:15 -0500 (CDT) From: Brian Hurt X-X-Sender: bhurt@localhost.localdomain To: Fred Yankowski cc: Richard Jones , Subject: Re: [Caml-list] Printing text with holes In-Reply-To: <20030929220740.GA31853@ontosoft.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Loop: caml-list@inria.fr X-Spam: no; 0.00; caml-list:01 yankowski:01 gcc:01 printf:01 scanf:01 gcc:01 2.95.4:01 printf:01 spits:01 -wall:01 flags:01 sep:01 sep:01 compile:02 wrote:03 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk On Mon, 29 Sep 2003, Fred Yankowski wrote: > On Mon, Sep 29, 2003 at 10:52:34PM +0100, Richard Jones wrote: > > On this one small point, people who have been using gcc have had > > type safe printf/scanf for at least the last 15 years. > > What do you mean? Compiling the following with gcc 2.95.4 and > executing it causes a seg fault on my Linux 2.4.20 system: > > main() { printf("%s", 'a'); } > > It spits out warnings, not errors, if you add the -Wformat (or, alternatively, the -Wall) option to your compile flags. Brian ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners