Ok... Im about to go crazy. So i have a struct that has a char * within it.I malloc, say 100*sizeof(char), to allow 100 chars in there. Now, the user wants to add a null byte to struct->string. So I did it like this,
and it doesnt work...Code:struct->string = '\0'
Because later on, I am calling a function that returns the struct->string as a string and (im assuming) the null byte hasnt been written because its reading right past the null byte at struct->string... Is there something special I have to do?