I want to split a string and assign its parts to a struct. My current implementation causes a segmentation fault to occur, I am never allocating any memory. I am relatively new