char* pname = "Harry"
- From: erktek@xxxxxxxxx
- Date: 18 Apr 2006 01:18:34 -0700
Statement given below;
char * p ;
p = (char*) malloc(20);
p = "harry" ; // <------------- Is it perfectly valid ?
free(p);
.
- Follow-Ups:
- Re: char* pname = "Harry"
- From: John Bode
- Re: char* pname = "Harry"
- From: Ian Collins
- Re: char* pname = "Harry"
- Prev by Date: Re: Comparison function in qsort()
- Next by Date: Re: char* pname = "Harry"
- Previous by thread: Sorting & Searching
- Next by thread: Re: char* pname = "Harry"
- Index(es):