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

Fix response memory handling in handle_osp_scan #1364

Merged
merged 2 commits into from
Nov 30, 2020

Conversation

timopollmeier
Copy link
Member

@timopollmeier timopollmeier commented Nov 27, 2020

What:
When getting only the progress, the XML string is no longer requested
and when getting the full report, the string is freed in case of an
error.

Why:
The XML from the progress requests was never freed until the end of the scan,
so the strings kept consuming more and more memory, which could cause
problems during longer scans.

How did you test it:
By observing the memory consumption of the scan handler process in htop and
profiling gvmd with the massif tool of Valgrind while scanning a large range of
alive hosts.

Checklist:

When getting only the progress, the XML string is no longer requested
and when getting the full report, the string is freed in case of an
error.
@timopollmeier timopollmeier marked this pull request as ready for review November 27, 2020 08:41
@mattmundell mattmundell merged commit 3a9ca42 into greenbone:gvmd-20.08 Nov 30, 2020
@timopollmeier timopollmeier deleted the fix-osp-scan-20.08 branch October 15, 2021 12:07
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.

2 participants