Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!rutgers!ames!ptsfa!maxepr!cgh!amanue!pitt!cisunx!cmf From: cmf@cisunx.UUCP (Carl M. Fongheiser) Newsgroups: comp.os.minix Subject: Re: Bug in library routine getenv() Message-ID: <3567@cisunx.UUCP> Date: Wed, 13-May-87 10:06:53 EDT Article-I.D.: cisunx.3567 Posted: Wed May 13 10:06:53 1987 Date-Received: Mon, 18-May-87 06:37:05 EDT References: <3860@cae780.TEK.COM> <868@mimir.dmt.oz> <2494@ncoast.UUCP> <3569@spool.WISC.EDU> Reply-To: cmf@cisunx.UUCP (Carl M. Fongheiser) Organization: Univ. of Pittsburgh, Comp & Info Sys Lines: 14 According to my V7 manual: "Strncpy copies exactly n characters, truncating or null-padding s2; the target may not be null-terminated if the length of s2 is n or more." ^^^ ^^^ ^^ ^^^^^^^^^^^^^^^ In other words, V7 won't guarantee which way it works, and if you want to run on a V7 machine, you better not depend on any particular behavior. Carl Fongheiser University of Pittsburgh Computing & Information Systems ...!pitt!cisunx!cmf cmf@pittvms.BITNET