diff options
Diffstat (limited to 'src/libfaad/hcr.c')
-rw-r--r-- | src/libfaad/hcr.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/libfaad/hcr.c b/src/libfaad/hcr.c index d5652aa18..aa282f32d 100644 --- a/src/libfaad/hcr.c +++ b/src/libfaad/hcr.c @@ -16,7 +16,7 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: hcr.c,v 1.1 2002/12/16 19:00:10 miguelfreitas Exp $ +** $Id: hcr.c,v 1.2 2003/04/12 14:58:47 miguelfreitas Exp $ **/ #include "common.h" @@ -548,6 +548,10 @@ uint8_t reordered_spectral_data(faacDecHandle hDecoder, ic_stream *ics, bitfile } /* of sfb */ } /* of presort */ + /* Avoid divide by zero */ + if (numberOfSegments == 0) + return 10; /* this is not good... */ + numberOfSets = NrCodeWords / numberOfSegments; /* second step: decode nonPCWs */ |