Segmentation faults and general protection faults usually mean that you've gone and written to or read from memory that you do not have the rights too. This can happen if you're actively using a pointer that hasn't been set to point to anything in particular, using a pointer in the wrong way (like typecasting it to point to a different type of data when you don't know what you're doing), or going off the ends of arrays (off by one errors are very common).
Comments