}
// Export module sections before the template section.
- if (strcmp(item->name + 1, C_TPL + 1) == 0) {
+ if (strcmp(&item->name[1], &C_TPL[1]) == 0) {
for (yp_item_t *mod = item + 1; mod->name != NULL; mod++) {
// Skip non-module sections.
if (strncmp(mod->name + 1, mod_prefix, mod_prefix_len) != 0) {
return val;
default:
CONF_LOG_ZONE(LOG_ERR, dname, "failed to read '%s/%s' (%s)",
- C_ZONE + 1, key1_name + 1, knot_strerror(val.code));
+ &C_ZONE[1], &key1_name[1], knot_strerror(val.code));
// FALLTHROUGH
case KNOT_ENOENT:
break;
break;
default:
CONF_LOG_ZONE(LOG_ERR, dname, "failed to read '%s/%s' (%s)",
- C_ZONE + 1, C_TPL + 1, knot_strerror(val.code));
+ &C_ZONE[1], &C_TPL[1], knot_strerror(val.code));
// FALLTHROUGH
case KNOT_ENOENT:
case KNOT_YP_EINVAL_ID:
switch (val.code) {
default:
CONF_LOG_ZONE(LOG_ERR, dname, "failed to read '%s/%s' (%s)",
- C_TPL + 1, key1_name + 1, knot_strerror(val.code));
+ &C_TPL[1], &key1_name[1], knot_strerror(val.code));
// FALLTHROUGH
case KNOT_EOK:
case KNOT_ENOENT:
switch (val.code) {
default:
CONF_LOG(LOG_ERR, "failed to read default '%s/%s' (%s)",
- C_TPL + 1, key1_name + 1, knot_strerror(val.code));
+ &C_TPL[1], &key1_name[1], knot_strerror(val.code));
// FALLTHROUGH
case KNOT_EOK:
case KNOT_ENOENT:
if (val.code == KNOT_EOK) { \
CONF_LOG(LOG_NOTICE, "option 'template.%s' is obsolete, " \
"use option 'database.%s' instead", \
- old_item + 1, new_item + 1); \
+ &old_item[1], &new_item[1]); \
}