svn commit: r237223 - head/sys/dev/fb
Daniel O'Connor
doconnor at gsoft.com.au
Tue Jun 19 02:17:50 UTC 2012
On 18/06/2012, at 19:04, Gennady Proskurin wrote:
>> Modified: head/sys/dev/fb/fbreg.h
>> ==============================================================================
>> --- head/sys/dev/fb/fbreg.h Mon Jun 18 07:43:23 2012 (r237222)
>> +++ head/sys/dev/fb/fbreg.h Mon Jun 18 07:54:10 2012 (r237223)
>> @@ -39,6 +39,7 @@
>> static __inline void
>> copyw(uint16_t *src, uint16_t *dst, size_t size)
>> {
>> + size >>= 1;
>> while (size--)
>> *dst++ = *src++;
>> }
>
> If size is odd, this does not copy the last byte. Not sure, whether this is intended.
Add
KASSERT(size & 0x1 == 0, ("odd size copy"));
before
size >>= 1;
:)
--
Daniel O'Connor software and network engineer
for Genesis Software - http://www.gsoft.com.au
"The nice thing about standards is that there
are so many of them to choose from."
-- Andrew Tanenbaum
GPG Fingerprint - 5596 B766 97C0 0E94 4347 295E E593 DC20 7B3F CE8C
More information about the svn-src-head
mailing list