Thread (10 messages) flat view 10 messages, 5 authors, 2016-06-15

Re: [PATCH] general style: replaces memcmp() with starts_with()

From: Duy Nguyen <hidden>
Date: 2016-06-15 23:00:18

On Thu, Mar 13, 2014 at 12:22 AM, Jens Lehmann [off-list ref] wrote:
That spot uses memcmp() because ce->name may
not be 0-terminated.
ce->name is 0-terminated (at least if it's created the normal way, I
haven't checked where this "ce" in submodule.c comes from).
ce_namelen() is just an optimization because we happen to store name's
length if it's shorter than 4096, so there's no need to
strlen(ce->name) again.
-- 
Duy
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help