Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!usc!samsung!sdd.hp.com!think.com!mintaka!bloom-picayune.mit.edu!ahodgson From: ahodgson@athena.mit.edu (Antony Hodgson) Newsgroups: comp.lang.c++ Subject: Is it okay to use delete after malloc? Message-ID: <1991Jan29.150219.28884@athena.mit.edu> Date: 29 Jan 91 15:02:19 GMT Sender: news@athena.mit.edu (News system) Distribution: usa Organization: Massachusetts Institute of Technology Lines: 11 If I create a string using one of the library routines such as strdup, is it then acceptable to use delete, or is free() required? E.g.: char* s; s = strdup( "Test" ); delete s; // or free(s)? Tony Hodgson ahodgson@hstbme.mit.edu