Re: [PATCH 4/4] streaming filter: ident filter and filter cascading

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am 21.05.2011 23:05, schrieb René Scharfe:
>> +		if (ident->state < sizeof(head) &&
> 
> 		// minus one because otherwise we'd compare the
> 		// terminating NUL as well even though we're not
> 		// actually looking for a NUL
> 		if (ident->state < sizeof(head) - 1 &&

Possibly, but that doesn't matter, as the right number of characters is
remembered and the second test below is not passed if we sailed past the
NUL.  Sorry for the noise.

> 
>> +		    head[ident->state] == ch) {
>> +			ident->state++;
>> +			continue;
>> +		}
>> +
>> +		if (ident->state)
>> +			strbuf_add(&ident->left, head, ident->state);
>> +		if (ident->state == sizeof(head) - 1) {
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]