MCPcopy Create free account
hub / github.com/Meridian59/Meridian59 / SetString

Function SetString

blakserv/string.c:232–244  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

230}
231
232void 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
246void SetTempString(char *buf,int len)
247{

Callers 4

C_SetStringFunction · 0.85
C_MinigameNumberToStringFunction · 0.85
SetSubstringMethod · 0.85
SetPartialMethod · 0.85

Calls 1

SetTempStringFunction · 0.85

Tested by

no test coverage detected