ECONF\_SET\_CONF\_DIRS(3) libeconf Manual ECONF\_SET\_CONF\_DIRS(3)

# [NAME](#NAME)

econf\_set\_conf\_dirs - sets the list of configuration directory post-fixes

# [SYNOPSIS](#SYNOPSIS)

```
#include <libeconf.h>
```

**econf\_err econf\_set\_conf\_dirs(const char \*\*dir\_postfix\_list);**

# [DESCRIPTION](#DESCRIPTION)

The **econf\_set\_conf\_dirs**() function sets a list of directory structures (with order) which describes the directories in which the files have to be parsed.

The argument *dir\_postfix\_list* is an array of null-terminated strings, terminated by a **NULL** pointer.

E.G. with the given list: {"/conf.d/", ".d/", "/", NULL} files in following directories will be parsed: &lt;default\_dirs&gt;/&lt;project\_name&gt;.&lt;suffix&gt;.d/ &lt;default\_dirs&gt;/&lt;project\_name&gt;/conf.d/, &lt;default\_dirs&gt;/&lt;project\_name&gt;.d/, &lt;default\_dirs&gt;/&lt;project\_name&gt;/. The entry &lt;default\_dirs&gt;/&lt;project\_name&gt;.&lt;suffix&gt;.d/ will be added automatically.

# [RETURN VALUE](#RETURN_VALUE)

On success, **econf\_set\_conf\_dirs**() returns **ECONF\_SUCCESS**.

On failure, an error code of type **econf\_err** is returned.

# [ERRORS](#ERRORS)

**ECONF\_NOMEM**

Out of memory.

# [SEE ALSO](#SEE_ALSO)

[**libeconf**(3)](/man/os/libeconf/libeconf.3), [**econf\_readConfig**(3)](/man/os/libeconf/econf_readConfig.3), [**econf\_errString**(3)](/man/os/libeconf/econf_errString.3).

2025-12-04 libeconf

---

Document: econf_set_conf_dirs(3) from libeconf 0.8.6-r2 (Chainguard OS)
Source: https://github.com/openSUSE/libeconf
