Newsgroups: comp.lang.c
Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!sol.ctr.columbia.edu!ira.uka.de!fauern!faui43.informatik.uni-erlangen.de!richter
From: richter@immd4.informatik.uni-erlangen.de (Joachim Richter)
Subject: Re: pointer->pointer problem
Message-ID: <1991Apr5.094243.1380@informatik.uni-erlangen.de>
Reply-To: richter@medusa.UUCP ()
Organization: CSD., University of Erlangen, Germany 
References: <1991Apr3.174058.13536@bnlux1.bnl.gov>
Distribution: na
Date: Fri, 5 Apr 1991 09:42:43 GMT
Lines: 33

In article <1991Apr3.174058.13536@bnlux1.bnl.gov> reilly@bnlux1.bnl.gov (kevin reilly) writes:
>I have the following problem with a piece of code.
>If someone could please tell me what I am doing wrong I woulde be quite
>grateful!
>
>FUNC1 returns the address of an array of pointers to strings.
>FUNC2 does some string manipulations.
>
>main()
>{
>char **outPt;
>
>outPut = FUNC1(...);
>FUNC2(outPut);
>}
>
>char **FUNC1(...)
>{
>static char *lines[10];
>/* do stuff */
>return &lines[0];
>}
>
>void FUNC2(char **inPut)
>{
>/* If I manipulate the strings pointed to by inPut in this function
>	it seems other strings are also effected.
>   Why is this?
>*/
>}

Which *other* strings ? This is C, not ModulaOrAnotherWirthLessThing.
	Ingo
