↧
Answer by David Schwartz for C pointers segmentation fault crash
strcpy(director[i]->code, dataPtr[i]->code); //It crashes in this Line At this point, director[i] doesn't point to anything. You need a director[i] = calloc(... line just like in...
View ArticleC pointers segmentation fault crash
// Struct for Country Datatypedef struct{ char name[50]; // Country name char code[3]; // Country code int population; // Country Population double lifeExp; // Country Life expectancy } CountryData;//...
View Article
More Pages to Explore .....