From: Elliott Oti Newsgroups: comp.os.msdos.djgpp Subject: Re: Strange Behaviour ... Date: Tue, 28 Jan 1997 06:04:28 -0800 Organization: Academic Computer Centre Utrecht, (ACCU) Lines: 24 Message-ID: <32EE076C.7FA7@stud.warande.ruu.nl> References: <32EDEBC4 DOT 49E1 AT eagle DOT patra DOT hol DOT gr> NNTP-Posting-Host: warande1078.warande.ruu.nl Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Panos Platon Tsapralis wrote: > > Dear friends, > > I have been spending endless hours of work, trying to figure out why > the DJGPP compiler has this strange behaviour that I present below : > > .. > char buffer[2048] > .. > int main(void) > > { > .. > strcpy(buffer,"string1"); /* Works O.K. - RHIDE debugger shows > buffer="string1" ... */ > .. > strcpy(buffer,"string2"); /* Old content of 'buffer' vanishes - RHIDE > debugger shows buffer="" !!! */ > .. > return(...); > } Is string2 longer than string1 ?