return t->parse(filename, line, section, lvalue, rvalue, t->data, userdata);
}
- fprintf(stderr, "[%s:%u] Unknown lvalue '%s' in section '%s'.", filename, line, lvalue, strna(section));
+ fprintf(stderr, "[%s:%u] Unknown lvalue '%s' in section '%s'.\n", filename, line, lvalue, strna(section));
return -EBADMSG;
}
assert(k > 0);
if (b[k-1] != ']') {
- fprintf(stderr, "[%s:%u] Invalid section header.", filename, line);
+ fprintf(stderr, "[%s:%u] Invalid section header.\n", filename, line);
return -EBADMSG;
}
}
if (!(e = strchr(b, '='))) {
- fprintf(stderr, "[%s:%u] Missing '='.", filename, line);
+ fprintf(stderr, "[%s:%u] Missing '='.\n", filename, line);
return -EBADMSG;
}
if (!(f = fopen(filename, "re"))) {
r = -errno;
- fprintf(stderr, "Failed to open configuration file '%s': %s", filename, strerror(-r));
+ fprintf(stderr, "Failed to open configuration file '%s': %s\n", filename, strerror(-r));
goto finish;
}
break;
r = -errno;
- fprintf(stderr, "Failed to read configuration file '%s': %s", filename, strerror(-r));
+ fprintf(stderr, "Failed to read configuration file '%s': %s\n", filename, strerror(-r));
goto finish;
}
assert(data);
if ((r = safe_atoi(rvalue, i)) < 0) {
- fprintf(stderr, "[%s:%u] Failed to parse numeric value: %s", filename, line, rvalue);
+ fprintf(stderr, "[%s:%u] Failed to parse numeric value: %s\n", filename, line, rvalue);
return r;
}
assert(data);
if ((r = safe_atou(rvalue, u)) < 0) {
- fprintf(stderr, "[%s:%u] Failed to parse numeric value: %s", filename, line, rvalue);
+ fprintf(stderr, "[%s:%u] Failed to parse numeric value: %s\n", filename, line, rvalue);
return r;
}
assert(data);
if ((r = safe_atou(rvalue, &u)) < 0) {
- fprintf(stderr, "[%s:%u] Failed to parse numeric value: %s", filename, line, rvalue);
+ fprintf(stderr, "[%s:%u] Failed to parse numeric value: %s\n", filename, line, rvalue);
return r;
}
assert(data);
if ((k = parse_boolean(rvalue)) < 0) {
- fprintf(stderr, "[%s:%u] Failed to parse boolean value: %s", filename, line, rvalue);
+ fprintf(stderr, "[%s:%u] Failed to parse boolean value: %s\n", filename, line, rvalue);
return k;
}