[theora-dev] _ilog() method

Cesar Oliveira cesar.d.o at vif.com
Wed Mar 21 21:30:51 PDT 2007


While digging into the code and reading the spec, I noticed that _ilog
doesn't properly return 0 when a negative number is passed because it
only accepts unsigned integers. An unsigned -1 (0xFFFFFF) would return
the number of bits in an int, rather than 0.

And it's an easy fix (and hopefully I am correct), so I'm sending it in. :)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ilog.patch
Type: text/x-patch
Size: 482 bytes
Desc: not available
Url : http://lists.xiph.org/pipermail/theora-dev/attachments/20070321/817d89ae/ilog.bin


More information about the theora-dev mailing list