Re: [PATCH] SBC Encoder program

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

 



On Monday 05 January 2009 16:42:39 ext Christian Hoene wrote:
> > Just the codesize is 16 bit, right? So I guess the following changes
> > are not really necessary:
> >
> >
> > +	uint16_t subbands, channels, blocks;
>
> No, but then we have to change the last line of the function to
>   return ((uint16_t)subbands) * blocks * channels * 2;

Not quite so. There is such thing as "integer promotion" defined in C
standard. And integer type is guaranteed to be at least 16 bit. But I
agree that explicitly having uint16_t is much more likely not to raise
any doubts about its correctness :)

-- 
Best regards,
Siarhei Siamashka
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux