bb->consumed_bits = 0;
bb->total_consumed_bits = FLAC__BLURBS_TO_BITS(new_capacity);
}
- free(bb->buffer); // we've already asserted above that (bb->buffer != 0)
+ free(bb->buffer); /* we've already asserted above that (bb->buffer != 0) */
bb->buffer = new_buffer;
bb->capacity = new_capacity;
return true;
FLAC__byte FLAC__bitbuffer_get_write_crc8(const FLAC__BitBuffer *bb)
{
FLAC__ASSERT(0 != bb);
- //@@@ WHY WAS THIS HERE? FLAC__ASSERT(bb->blurbs == 0);
- FLAC__ASSERT(bb->buffer[0] == 0xff); /* MAGIC NUMBER for the first byte of the sync code */
FLAC__ASSERT((bb->bits & 7) == 0); /* assert that we're byte-aligned */
+ FLAC__ASSERT(bb->buffer[0] == 0xff); /* MAGIC NUMBER for the first byte of the sync code */
#if FLAC__BITS_PER_BLURB == 8
return FLAC__crc8(bb->buffer, bb->blurbs);
#elif FLAC__BITS_PER_BLURB == 32
return false;
}
#if FLAC__BITS_PER_BLURB > 8
- if(bb->bits == 0 || bb->consumed_blurbs < bb->blurbs) { //@@@ comment on why this is here
+ if(bb->bits == 0 || bb->consumed_blurbs < bb->blurbs) { /*@@@ comment on why this is here*/
#endif
if(bb->consumed_bits) {
i = FLAC__BITS_PER_BLURB - bb->consumed_bits;
return false;
}
#if FLAC__BITS_PER_BLURB > 8
- if(bb->bits == 0 || bb->consumed_blurbs < bb->blurbs) { //@@@ comment on why this is here
+ if(bb->bits == 0 || bb->consumed_blurbs < bb->blurbs) { /*@@@ comment on why this is here*/
#endif
if(bb->consumed_bits) {
i = FLAC__BITS_PER_BLURB - bb->consumed_bits;
return false;
}
#if FLAC__BITS_PER_BLURB > 8
- if(bb->bits == 0 || bb->consumed_blurbs < bb->blurbs) { //@@@ comment on why this is here
+ if(bb->bits == 0 || bb->consumed_blurbs < bb->blurbs) { /*@@@ comment on why this is here*/
#endif
if(bb->consumed_bits) {
i = FLAC__BITS_PER_BLURB - bb->consumed_bits;
return false;
}
#if FLAC__BITS_PER_BLURB > 8
- if(bb->bits == 0 || bb->consumed_blurbs < bb->blurbs) { //@@@ comment on why this is here
+ if(bb->bits == 0 || bb->consumed_blurbs < bb->blurbs) { /*@@@ comment on why this is here*/
#endif
if(bb->consumed_bits) {
i = FLAC__BITS_PER_BLURB - bb->consumed_bits;
FLAC__ASSERT(bb->buffer != 0);
#if FLAC__BITS_PER_BLURB > 8
- if(bb->bits == 0 || bb->consumed_blurbs < bb->blurbs) { //@@@ comment on why this is here
+ if(bb->bits == 0 || bb->consumed_blurbs < bb->blurbs) { /*@@@ comment on why this is here*/
#endif
if(bb->consumed_bits) {
b = bb->buffer[bb->consumed_blurbs] << bb->consumed_bits;
}
else {
fprintf(out, "bitbuffer: capacity=%u blurbs=%u bits=%u total_bits=%u consumed: blurbs=%u, bits=%u, total_bits=%u\n", bb->capacity, bb->blurbs, bb->bits, bb->total_bits, bb->consumed_blurbs, bb->consumed_bits, bb->total_consumed_bits);
-return;//@@@
+return;/*@@@*/
for(i = 0; i < bb->blurbs; i++) {
fprintf(out, "%08X: ", i);
for(j = 0; j < FLAC__BITS_PER_BLURB; j++)