Subject: Re: port-xen/29887: sysctl kern.consdev coredumps
To: None <port-xen-maintainer@netbsd.org, gnats-admin@netbsd.org,>
From: Jachym Holecek <freza@liberouter.org>
List: netbsd-bugs
Date: 06/20/2005 16:19:02
The following reply was made to PR port-xen/29887; it has been noted by GNATS.

From: Jachym Holecek <freza@liberouter.org>
To: Alan Barrett <apb@cequrux.com>
Cc: gnats-bugs@NetBSD.org, netbsd-bugs@NetBSD.org,
	tech-userlevel@NetBSD.org
Subject: Re: port-xen/29887: sysctl kern.consdev coredumps
Date: Mon, 20 Jun 2005 18:18:05 +0200

 Hello,
 
 > > A compiler by your logic could completely supply libc internally and
 > > not call your system supplied one with extentions you may be depending
 > > on.
 > 
 > Yes, a compiler could do that, to the extent permitted by the
 > standards that you tell the compiler to use.  Again, don't tell the
 > compiler "-std=c99" if you are relying on printf("%s",NULL) to print
 > "(null)", or if you are relying on any other non-standard extensions to
 > standard-defined functions.
 
 If the standard leaves behaviour as not-strictly-defined, then the compiler
 should delegate behaviour to the implementation, ie. compiler is not free
 to be smart in such case. So, unless 'fputs(NULL, x)' is defined to behave
 the same as 'printf("%s", NULL)', then I'd call blind printf->fputs
 substition "not good". IANAL though...
 
 	Regards,
 		-- Jachym Holecek