Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!samsung!rex!rouge!gator.cacs.usl.edu From: pcb@gator.cacs.usl.edu (Peter C. Bahrs) Newsgroups: comp.lang.c Subject: Should I free strtok() results? Message-ID: <6501@rouge.usl.edu> Date: 10 Apr 90 05:17:18 GMT Sender: anon@rouge.usl.edu Organization: The Center for Advanced Computer Studies, USL Lines: 18 The string functions that return pointers to memory, should their results be freed? Most (if not all) of the sample code in QuickC using these do not free the results. In fact, most code that I have seen anywhere, these are not freed. It only makes sense to free them though. Any ideas? /*----------- Thanks in advance... --------------------------------------+ | Peter C. Bahrs | | The USL-NASA Project | | Center For Advanced Computer Studies INET: pcb@gator.cacs.usl.edu | | 2 Rex Street | | University of Southwestern Louisiana ...!uunet!dalsqnt!gator!pcb | | Lafayette, LA 70504 | +-----------------------------------------------------------------------*/