# HG changeset patch # User rtognimp # Date 1088334390 0 # Node ID bcc91fa6769460c2bec44d974a93db388d44d241 # Parent 6681dcffb5cfb47bcd3d7fe86da856f63efba429 fix for width or height not multiple of 4 diff -r 6681dcffb5cf -r bcc91fa67694 smc.c --- a/smc.c Sat Jun 26 15:00:26 2004 +0000 +++ b/smc.c Sun Jun 27 11:06:30 2004 +0000 @@ -125,7 +125,7 @@ chunk_size, s->size); chunk_size = s->size; - total_blocks = (s->avctx->width * s->avctx->height) / (4 * 4); + total_blocks = ((s->avctx->width + 3) / 4) * ((s->avctx->height + 3) / 4); /* traverse through the blocks */ while (total_blocks) {