-
Notifications
You must be signed in to change notification settings - Fork 27
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
appimage_read_file_into_buffer_following_symlinks #9
Conversation
Was quite a challenge to get to this point (I had to read into a lot of code, and performed quite some refactoring to make the code more maintainable), but this should do the job. @kbroulik please review/test. |
src/libappimage/type1.c
Outdated
#ifdef STANDALONE | ||
fprintf(stderr, "failed to read data into buffer: %s\n", archive_error_string(a)); | ||
#endif | ||
return false; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't you leak the buffer here, given you don't pass it outside for manual free()
but you also don't dispose of it in here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch, it must be free()
d of course.
@kbroulik and I tested this code with a lot of AppImages, and it appears to work fine. |
Great. Thanks @kbroulik and @TheAssassin |
Fixes #1.