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

Do not abort when log file not accessible #447

Merged
merged 3 commits into from
Feb 17, 2021

Conversation

ArnoStiefvater
Copy link
Member

@ArnoStiefvater ArnoStiefvater commented Feb 17, 2021

What:

Do not abort when trying to log to log file with wrong permissions.

If the error reported by setup_log_handlers is not handled the log domains with log files which can not be accessed will be ignored and some default is used instead.

Related to: greenbone/openvas-scanner#661

Why:

Fix greenbone/openvas-scanner#415.

How:

Checklist:

@ArnoStiefvater ArnoStiefvater changed the base branch from gvm-libs-20.08 to master February 17, 2021 13:42
@ArnoStiefvater ArnoStiefvater changed the base branch from master to gvm-libs-20.08 February 17, 2021 13:43
This function checks if a dir and log file exists
and if we are able write to it.
If this is not the case the function returns -1.
@ArnoStiefvater ArnoStiefvater changed the base branch from gvm-libs-20.08 to master February 17, 2021 13:49
If one of the domains has a log file or log
directory which is not readable -1 is returned.
This is not necessarily an abort worthy error if
it is acceptable for the caller to have log
messages logged to stderr instead.
@jjnicola jjnicola merged commit 1245a2a into greenbone:master Feb 17, 2021
@ArnoStiefvater ArnoStiefvater mentioned this pull request Mar 8, 2021
2 tasks
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

Successfully merging this pull request may close these issues.

[7.0.0] Coredump when the log file is not accessible.
2 participants