I am having a wierd issue. I am doing a simple strcat and getting a segmentation fault. Here is a code snippet.
This produces:Code:#include <stdio.h> #include <string.h> sname="/"; printf("2 %s & %s\n",sname, name); strcat(sname, name);
2 / & rb123121
Segmentation fault (core dumped)
Any ideas why this would happen? I have string.h included.
________________
Ok, after playing some more, it seems to be occuring with any string functions. I have all the right libraries included don't I?