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

0.3.DL notes and issues #78

Open
IS4Code opened this issue Feb 1, 2018 · 0 comments
Open

0.3.DL notes and issues #78

IS4Code opened this issue Feb 1, 2018 · 0 comments

Comments

@IS4Code
Copy link
Owner

IS4Code commented Feb 1, 2018

Since I cannot post these on the forum, I shall do so here, in hope that either Kalcor or YSF fixes them. Feel free to post your own issues you have found in the code.

  • AddSimpleModel & co. uses calloc to create CModelInfo, but it doesn't seem to free the memory if the creation fails (file not found). [not fixable without rewriting the code].
  • The same code returns 0 on failure (bad file), -1 on allocation fail, or any non-negative value for success. 0 is therefore also returned for the first model. [not fixable without changing the code and API]
  • Again in the same place, CArtList's size increases linearly instead of geometrically. The list has dynamic size and is reallocated every time a new model info is inserted, but the size is increased by 1 every time, resulting in 10000 calls to realloc for 10000 model insertions. The standard method is to double the size each time. [fixable by hooking the resize function]
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

No branches or pull requests

1 participant