home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / lang / c / 18864 < prev    next >
Encoding:
Text File  |  1992-12-24  |  676 b   |  22 lines

  1. Newsgroups: comp.lang.c
  2. Path: sparky!uunet!scifi!watson!danbob.vnet.ibm.com!gruber
  3. From: gruber@danbob.vnet.ibm.com (Scott Gruber)
  4. Subject: WHAT'S WRONG WITH THIS CODE  ... ???
  5. Sender: @watson.ibm.com
  6. Message-ID: <1992Dec24.135307.15926@watson.ibm.com>
  7. Date: Thu, 24 Dec 92 13:53:07 GMT
  8. Reply-To: gruber@danbob.vnet.ibm.com (Scott Gruber)
  9. Organization: IBM T. J. Watson Research Center
  10. Lines: 10
  11.  
  12. Taylor,
  13.        From what I can see in your code the 'p' pointer is not a result
  14. of a malloc
  15. which is what the function free is looking for. Reread the details of
  16. free and if
  17. you still want to use this then allocate memory for it using malloc then
  18. free should
  19. work.
  20.  
  21. Scott Gruber
  22.