I guess it wouldn't be a good design for the calling function to free memory that was allocated in the called function. Since the trimmed value could not be bigger than the *string parameter, I will...
Type: Posts; User: bbresc512
I guess it wouldn't be a good design for the calling function to free memory that was allocated in the called function. Since the trimmed value could not be bigger than the *string parameter, I will...
Hi all
say I have this function:
char *trim(char *string)
If I understand it correctly the function's result value has to be allocated, let's say, by malloc. But how is this allocation going to...