[pacman-dev] [PATCH] Clean up MD5 code.
Travis Willard
travis at archlinux.org
Thu Aug 16 18:09:58 EDT 2007
On Thu, 16 Aug 2007 14:45:40 -0400
"Dan McGee" <dpmcgee at gmail.com> wrote:
> Regarding the null byte thing- calloc zeros the memory, and while I
> would assume that is the same as the null byte,
It is. Setting the end of the string to '\0' (which == 0) is
unnecessary - but it won't waste much CPU time and it prevents issues
in the future (if it's ever changed from calloc to malloc again), so I
don't see a problem with it being there.
--
Travis
More information about the pacman-dev
mailing list