摘要: const char * 转换为 char *, 不能使用强制类型转换,应该用strcpy,也就是另开一块内存,把字符一个个复制过去 const char *str= "test is ok!"; char *str2= new char[strlen(str)+1]; strcpy(str2,st 阅读全文
posted @ 2011-08-26 11:40 hongweigg 阅读(82) 评论(0) 推荐(0)