I\'ve allocated a chuck of memory with char* memoryChunk = malloc ( 80* sizeof(char) + 1); What is keeping me from writing into the memory location beyond 81 un
Carl suggests strncpy(), which is a start in the right direction. The main idea is to develop the habit of avoiding buffer overflows by adopting specific practices. A more deliberate library for this is covered in strlcpy and strlcat--Consistent, Safe, String Copy and Concatenation.