Skip to content

Stop using strdup as it's not part of c99 - #35

Merged
spkrka merged 2 commits into
masterfrom
krka/strdup
Aug 17, 2016
Merged

spkrka merged 2 commits into
masterfrom
krka/strdup

Conversation

@spkrka

@spkrka spkrka commented Aug 14, 2016

Copy link
Copy Markdown
Member

No description provided.

@spkrka spkrka mentioned this pull request Aug 14, 2016
@Qix-

Qix- commented Aug 14, 2016

Copy link
Copy Markdown

I don't work for spotify but lgtm. 💃 That's how I would do it.

@nresare

nresare commented Aug 14, 2016

Copy link
Copy Markdown
Contributor

While I agree that strcpy would work in this case, I think that strncpy() would set a better precedent and also reduce the noise for people searching public github for strcpy() instances to exploit ;)

@spkrka

spkrka commented Aug 15, 2016

Copy link
Copy Markdown
Member Author

I'll just use memcpy instead of strcpy since we already know the exact length to copy.

@spkrka
spkrka merged commit ee53521 into master Aug 17, 2016
@spkrka
spkrka deleted the krka/strdup branch August 17, 2016 10:27
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.

3 participants