Re: [PATCH] Add git-imap-send.
- From
Johannes Schindelin <johannes.schindelin@gmx.de>
- Date
- Mar 9, 2006, 11:30 UTC
- Message-ID
- <Pine.LNX.4.63.0603091227560.20277@wbgn013.biozentrum.uni-wuerzburg.de>
- In-Reply-To
- <7vacbz7vod.fsf@assigned-by-dhcp.cox.net>
Hi,
On Thu, 9 Mar 2006, Junio C Hamano wrote:
Show 6 quoted lines
> Mike McCormack <mike@codeweavers.com> writes:
>
> > + if (!memcmp( "imaps:", val, 6 )) {
> > + if (!memcmp( "imap:", val, 5 ))
>
> Is val always longer than 5 or 6 bytes here?That does not matter, since they are strings, and the memcmp should not look further if they are shorter (because the comparison to '\0' failed already).
However, if !memcmp("imaps:", val, 6), it means that val starts with the string "imaps:", right? Then !memcmp("imap:", val, 5) must always fail, no?
Ciao, Dscho