Skip to content

Commit

Permalink
CONFDB: don't hard fail in add_implicit_services()
Browse files Browse the repository at this point in the history
if no explicitly configured domains found.

There are might be 'enable_files_domain = true' or app domains that
are expanded later.
  • Loading branch information
alexey-tikhonov committed Oct 9, 2024
1 parent 47b9cc1 commit 78544ac
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/confdb/confdb.c
Original file line number Diff line number Diff line change
Expand Up @@ -662,7 +662,8 @@ static errno_t add_implicit_services(struct confdb_ctx *cdb, TALLOC_CTX *mem_ctx

ret = confdb_get_enabled_domain_list(cdb, tmp_ctx, &domain_names);
if (ret == ENOENT) {
DEBUG(SSSDBG_OP_FAILURE, "No domains configured!\n");
/* confdb_expand_app_domains() wasn't called yet, so this might be ok */
ret = EOK;
goto done;
} else if (ret != EOK) {
DEBUG(SSSDBG_FATAL_FAILURE, "Error retrieving domains list [%d]: %s\n",
Expand Down
6 changes: 5 additions & 1 deletion src/monitor/monitor.c
Original file line number Diff line number Diff line change
Expand Up @@ -2056,7 +2056,11 @@ int main(int argc, const char *argv[])
}

monitor->cdb = main_ctx->confdb_ctx;
get_monitor_config(monitor);
ret = get_monitor_config(monitor);
if (ret = EOK) {

Check failure

Code scanning / CodeQL

Assignment where comparison was intended Error

Use of '=' where '==' may have been intended.
ret = 1;
goto out;
}
monitor->is_daemon = !opt_interactive;
monitor->parent_pid = main_ctx->parent_pid;
monitor->ev = main_ctx->event_ctx;
Expand Down

0 comments on commit 78544ac

Please sign in to comment.