summaryrefslogtreecommitdiff
path: root/DISTRO_PORTING
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2016-06-16 18:37:11 +0200
committerGitHub <noreply@github.com>2016-06-16 18:37:11 +0200
commit5278bbfe0c79c1f2b5bf8a215d8e7d63f1900ce9 (patch)
treead6cb407e6058b650eac2cb2132772f8c978ee08 /DISTRO_PORTING
parent79e21f7a71ad100788203b6e3c310571fd070197 (diff)
resolved: when restarting a transaction make sure to not touch it anymore (#3553)
dns_transaction_maybe_restart() is supposed to return 1 if the the transaction has been restarted and 0 otherwise. dns_transaction_process_dnssec() relies on this behaviour. Before this change in case of restart we'd call dns_transaction_go() when restarting the lookup, returning its return value unmodified. This is wrong however, as that function returns 1 if the transaction is pending, and 0 if it completed immediately, which is a very different set of return values. Fix this, by always returning 1 on redirection. The wrong return value resulted in all kinds of bad memory accesses as we might continue processing a transaction that was redirected and completed immediately (and thus freed). This patch also adds comments to the two functions to clarify the return values for the future. Most likely fixes: #2942 #3475 #3484
Diffstat (limited to 'DISTRO_PORTING')
0 files changed, 0 insertions, 0 deletions