return NULL;
}
-static char *__init get_value(const struct file *cfg, const char *section,
+static char *__init get_value(const struct file *file, const char *section,
const char *item)
{
- char *ptr = cfg->str, *end = ptr + cfg->size;
+ char *ptr = file->str, *end = ptr + file->size;
size_t slen = section ? strlen(section) : 0, ilen = strlen(item);
bool match = !slen;
return true;
}
-static void __init pre_parse(const struct file *cfg)
+static void __init pre_parse(const struct file *file)
{
- char *ptr = cfg->str, *end = ptr + cfg->size;
+ char *ptr = file->str, *end = ptr + file->size;
bool start = true, comment = false;
for ( ; ptr < end; ++ptr )
else
start = 0;
}
- if ( cfg->size && end[-1] )
+ if ( file->size && end[-1] )
PrintStr(L"No newline at end of config file,"
" last line will be ignored.\r\n");
}