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 slines handling in fgwrite.c #8

Merged
merged 2 commits into from
Aug 20, 2018
Merged

Fix slines handling in fgwrite.c #8

merged 2 commits into from
Aug 20, 2018

Conversation

olebole
Copy link
Member

@olebole olebole commented Aug 17, 2018

Don't increment slines after allocation, only reallocate it. Also fix the realloc() calling parameters.

This brings fgwrite back to work when a reallocation of slines was needed (the TOC contained more than 70 entries).

Closes #7.

Also, necessary #include statements are added to declare the standard functions.

Don't increment slines after allocation, only reallocate it. Also fix the
realloc() calling parameters.

This brings fgwrite back to work when a reallocation of slines was
needed (the TOC contained more than 70 entries).
@olebole olebole merged commit 371234c into iraf-community:master Aug 20, 2018
@olebole olebole deleted the fix_fgwrite branch August 20, 2018 06:45
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.

fgwrite: memory allocation trouble
1 participant