home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / lang / cplus / 16192 < prev    next >
Encoding:
Internet Message Format  |  1992-11-13  |  1.0 KB

  1. Path: sparky!uunet!know!cass.ma02.bull.com!mips2!news.bbn.com!usc!zaphod.mps.ohio-state.edu!wupost!darwin.sura.net!convex!news.utdallas.edu!corpgate!bnrgate!bnr.co.uk!pipex!demon!trmphrst.demon.co.uk!nikki
  2. From: nikki@trmphrst.demon.co.uk (Nikki Locke)
  3. Newsgroups: comp.lang.c++
  4. Subject: Re: Debugging output
  5. Message-ID: <721508490snx@trmphrst.demon.co.uk>
  6. Date: 11 Nov 92 12:01:30 GMT
  7. Sender: usenet@gate.demon.co.uk
  8. Reply-To: nikki@trmphrst.demon.co.uk
  9. Organization: Trumphurst Ltd.
  10. Lines: 15
  11. X-Mailer: cppnews $Revision: 1.20 $
  12.  
  13. In article <DAVIDM.92Nov7163528@consilium.com> davidm@consilium.com (David S. Masterson) writes:
  14. > void
  15. > Tracer::SetWatch(char* name)
  16. > {
  17. >         if (watch)
  18. >                 delete watch;
  19. >         watch = new char[strlen(name)];
  20.                            ^^^^^^^^^^^^ Oops !
  21. Ever get unexplained core dumps using this ?
  22. >         strcpy(watch, name);
  23. > }
  24. -- 
  25. Nikki Locke,Trumphurst Ltd.(PC and Unix consultancy) nikki@trmphrst.demon.co.uk
  26. trmphrst.demon.co.uk is NOT affiliated with ANY other sites at demon.co.uk.
  27.