const char *mime_type,
const char *file_name)
{
- if(!mtil) return;
+ if(!mtil || !mime_type || !file_name) return;
mime_type_info **mti;
int found = 0;
/* read globs2, and construct data structure */
globs2 = fopen(GLOBS2_PATH, "r");
+ if (!globs2) return;
+
char *weight, *mime_type, *file_name, *saveptr = NULL;
while(fgets(buf, 255, globs2)) {
/* skip comment */