| 230 | } |
| 231 | |
| 232 | void SetString(string_node *snod,char *buf,int len) |
| 233 | { |
| 234 | if (snod == &temp_str) |
| 235 | { |
| 236 | SetTempString(buf,len); |
| 237 | return; |
| 238 | } |
| 239 | FreeMemory(MALLOC_ID_STRING,snod->data,snod->len_data+1); |
| 240 | snod->data = (char *)AllocateMemory(MALLOC_ID_STRING,len+1); |
| 241 | memcpy(snod->data,buf,len); |
| 242 | snod->len_data = len; |
| 243 | snod->data[snod->len_data] = '\0'; |
| 244 | } |
| 245 | |
| 246 | void SetTempString(char *buf,int len) |
| 247 | { |
no test coverage detected