Skip to content

memset start position , default value and number of bytes to fill#26

Open
SupriseYang wants to merge 1 commit into
zedshaw:masterfrom
SupriseYang:patch-1
Open

memset start position , default value and number of bytes to fill#26
SupriseYang wants to merge 1 commit into
zedshaw:masterfrom
SupriseYang:patch-1

Conversation

@SupriseYang
Copy link
Copy Markdown

memset(array->contents + old_max, 0, array->expand_rate * sizeof(void *));

memset(array->contents + old_max, 0, array->expand_rate * sizeof(void *));
@JanWartenberg
Copy link
Copy Markdown

Yep. I stumbled over the same thing.
It causes issues when you do the extra credit and benchmark, and create/clear lists multiple times with growing sizes.

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