Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

opendmarc/opendmarc.c:dmarfc_config_free: don't assert conf->conf_refcnt == 0 #18

Open
dilyanpalauzov opened this issue May 29, 2018 · 5 comments

Comments

@dilyanpalauzov
Copy link
Contributor

As described at trusteddomainproject/OpenDKIM#22.

diff --git a/opendmarc/opendmarc.c b/opendmarc/opendmarc.c
--- a/opendmarc/opendmarc.c
+++ b/opendmarc/opendmarc.c
@@ -3932,7 +3932,6 @@ static void
 dmarcf_config_free(struct dmarcf_config *conf)
 {
        assert(conf != NULL);
-       assert(conf->conf_refcnt == 0);
 
        if (conf->conf_data != NULL)
                config_free(conf->conf_data);
@thegushi
Copy link
Collaborator

This has been removed in the develop branch.

@dilyanpalauzov
Copy link
Contributor Author

On the develop branch conf_refcnt is still present.

@thegushi
Copy link
Collaborator

thegushi commented Apr 8, 2021 via email

@mskucherawy
Copy link
Member

Reopening as it needs to be resolved for OpenDMARC. It's still present on "develop".

@mskucherawy mskucherawy reopened this Apr 12, 2021
@leres
Copy link

leres commented Apr 15, 2024

I'm running 1.4.2 on FreeBSD 13.3-RELEASE and recently started seeing crashes. I built with debug symbols and left opendmarc running from gdb. The next time it crashed I got this stack trace:

Thread 1 received signal SIGABRT, Aborted.
Sent by thr_kill() from pid 30872 and user 26.
0x000000080044041a in thr_kill () from /lib/libc.so.7
(gdb) bt
#0  0x000000080044041a in thr_kill () from /lib/libc.so.7
#1  0x00000008003b9e64 in raise () from /lib/libc.so.7
#2  0x000000080046a6f9 in abort () from /lib/libc.so.7
#3  0x000000080039d201 in __assert () from /lib/libc.so.7
#4  0x0000000000210c0f in dmarcf_config_free (conf=0x800a1a000)
    at opendmarc.c:4162
#5  0x0000000000213460 in main (argc=11, argv=0x7fffffffe2e8)
    at opendmarc.c:5323

Line 4162 is the one referenced in this issue:

assert(conf->conf_refcnt == 0);

I came to github, did a search for conf_refcnt, and found this issue. Should this problematic assert() be removed or not?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants