char *tokstr = data.ToNewCString();
char *tokstr = ToNewCString(data);
void SetDataArray(nsString data){#if defined(DEBUG_profile)	printf("ProfileManager : Setting new profile data\n");	printf("SetDataArray data : %s\n", data.ToNewCString());#endif	int index = 0;	char *newStr=nsnull;	char *tokstr = data.ToNewCString();	char *token = nsCRT::strtok(tokstr, "%", &newStr);#if defined(DEBUG_profile)	printf("before while loop\n");#endif	while (token)    {#if defined(DEBUG_profile)	printf("subTok : %s\n", token);#endif    		PL_strcpy(gNewAccountData[index], token);		index++;		g_Count = index;      		token = nsCRT::strtok(newStr, "%", &newStr);    }  	delete[] tokstr;#if defined(DEBUG_profile)  printf("after while loop\n");#endif}