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

cURL and StringIO objects in the Opencast adapter are not closed properly #562

Closed
sinhote opened this issue Nov 21, 2017 · 0 comments
Closed
Labels

Comments

@sinhote
Copy link
Contributor

sinhote commented Nov 21, 2017

This has been around for a while and it bothers me everytime I have to browse through the code: both StringIO and cURL objects used in the Opencast client need to be properly closed, but they are handled in an "unsafe" way (if an error occurs, neither the cURL nor the StringIO object are properly closed).

I know for a fact that older versions of Galicaster would get slower and slower (until they simply malfunctioned) when the active parameter in the [ingest] section was set to true with an incorrect or unreachable URL. I do not know if leaving these objects open when the connection fails does have any noticeable consequences in the stability of Galicaster, but it is bad programming style in any case.

sinhote pushed a commit to sinhote/Galicaster that referenced this issue Nov 21, 2017
Alfro added a commit that referenced this issue Jan 17, 2018
Fix #562 : Properly close the cURL and StringIO objects
@Alfro Alfro added the bug label Jan 22, 2018
@Alfro Alfro closed this as completed in c938fc8 Jan 23, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants