KDrive: Warning fixes and cleanups

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
This commit is contained in:
Daniel Stone 2009-04-25 22:11:19 +10:00
commit 305ab237f6
11 changed files with 32 additions and 359 deletions

View file

@ -595,7 +595,7 @@ hostx_calculate_color_shift(unsigned long mask)
{
int shift = 1;
/* count # of bits in mask */
while (mask=(mask>>1)) shift++;
while ((mask = (mask >> 1))) shift++;
/* cmap entry is an unsigned char so adjust it by size of that */
shift = shift - sizeof(unsigned char) * 8;
if (shift < 0) shift = 0;