libavcodec/hqx.c:589: error: Uninitialized Value
  The value read from slice_off[_] was never initialized.

libavcodec/hqx.c:589:13: 
587. 
588.     for (slice = 0; slice < 16; slice++) {
589.         if (slice_off[slice] < HQX_HEADER_SIZE ||
                 ^
590.             slice_off[slice] >= slice_off[slice + 1] ||
591.             slice_off[slice + 1] > data_size) {

static int hqx_decode_frame(AVCodecContext *avctx, void *data,
                            int *got_picture_ptr, AVPacket *avpkt)
{
    HQXContext *ctx = avctx->priv_data;
    AVFrame *pic = data;
    uint8_t *src = avpkt->data;
    uint32_t info_tag, info_offset;
    int data_start;
    unsigned data_size;
    GetBitContext gb;
    int i, ret;
    int slice;
    uint32_t slice_off[17];
    mb_decode_func decode_func = 0;
    if (avpkt->size < 8)
        return AVERROR_INVALIDDATA;
    info_offset = 0;
    info_tag    = AV_RL32(src);
    if (info_tag == MKTAG('I', 'N', 'F', 'O')) {
        info_offset = AV_RL32(src + 4);
        if (info_offset > UINT32_MAX - 8 || info_offset + 8 > avpkt->size) {
            av_log(avctx, AV_LOG_ERROR,
                   "Invalid INFO header offset: 0x%08"PRIX32" is too large.\n",
                   info_offset);
            return AVERROR_INVALIDDATA;
        }
        info_offset += 8;
        src         += info_offset;
        av_log(avctx, AV_LOG_DEBUG, "Skipping INFO chunk.\n");
    }
    data_start = src - avpkt->data;
    data_size  = avpkt->size - data_start;
    if (data_size < HQX_HEADER_SIZE) {
        av_log(avctx, AV_LOG_ERROR, "Frame too small.\n");
        return AVERROR_INVALIDDATA;
    }
    if (src[0] != 'H' || src[1] != 'Q') {
        av_log(avctx, AV_LOG_ERROR, "Not an HQX frame.\n");
        return AVERROR_INVALIDDATA;
    }
    ctx->interlaced = !(src[2] & 0x80);
    ctx->format     = src[2] & 7;
    ctx->dcb        = (src[3] & 3) + 8;
    ctx->width      = AV_RB16(src + 4);
    ctx->height     = AV_RB16(src + 6);
    for (i = 0; i < 17; i++)
        slice_off[i] = AV_RB24(src + 8 + i * 3);
    if (ctx->dcb == 8) {
        av_log(avctx, AV_LOG_ERROR, "Invalid DC precision %d.\n", ctx->dcb);
        return AVERROR_INVALIDDATA;
    }
    ret = av_image_check_size(ctx->width, ctx->height, 0, avctx);
    if (ret < 0) {
        av_log(avctx, AV_LOG_ERROR, "Invalid stored dimenstions %dx%d.\n",
               ctx->width, ctx->height);
        return AVERROR_INVALIDDATA;
    }
    avctx->coded_width         = FFALIGN(ctx->width,  16);
    avctx->coded_height        = FFALIGN(ctx->height, 16);
    avctx->width               = ctx->width;
    avctx->height              = ctx->height;
    avctx->bits_per_raw_sample = 10;
    switch (ctx->format) {
    case HQX_422:
        avctx->pix_fmt = AV_PIX_FMT_YUV422P16;
        decode_func = hqx_decode_422;
        break;
    case HQX_444:
        avctx->pix_fmt = AV_PIX_FMT_YUV444P16;
        decode_func = hqx_decode_444;
        break;
    case HQX_422A:
        avctx->pix_fmt = AV_PIX_FMT_YUVA422P16;
        decode_func = hqx_decode_422a;
        break;
    case HQX_444A:
        avctx->pix_fmt = AV_PIX_FMT_YUVA444P16;
        decode_func = hqx_decode_444a;
        break;
    }
    if (!decode_func) {
        av_log(avctx, AV_LOG_ERROR, "Invalid format: %d.\n", ctx->format);
        return AVERROR_INVALIDDATA;
    }
    ret = ff_get_buffer(avctx, pic, 0);
    if (ret < 0) {
        av_log(avctx, AV_LOG_ERROR, "Could not allocate buffer.\n");
        return ret;
    }
    for (slice = 0; slice < 16; slice++) {
        if (slice_off[slice] < HQX_HEADER_SIZE ||
            slice_off[slice] >= slice_off[slice + 1] ||
            slice_off[slice + 1] > data_size) {
            av_log(avctx, AV_LOG_ERROR, "Invalid slice size.\n");
            break;
        }
        ret = init_get_bits(&gb, src + slice_off[slice],
                            (slice_off[slice + 1] - slice_off[slice]) * 8);
        if (ret < 0)
            return ret;
        ret = decode_slice(ctx, pic, &gb, slice, decode_func);
        if (ret < 0) {
            av_log(avctx, AV_LOG_ERROR, "Error decoding slice %d.\n", slice);
        }
    }
    pic->key_frame = 1;
    pic->pict_type = AV_PICTURE_TYPE_I;
    *got_picture_ptr = 1;
    return avpkt->size;
}
['static int hqx_decode_frame(AVCodecContext *avctx, void *data,\n                            int *got_picture_ptr, AVPacket *avpkt)\n{\n    HQXContext *ctx = avctx->priv_data;\n    AVFrame *pic = data;\n    uint8_t *src = avpkt->data;\n    uint32_t info_tag, info_offset;\n    int data_start;\n    unsigned data_size;\n    GetBitContext gb;\n    int i, ret;\n    int slice;\n    uint32_t slice_off[17];\n    mb_decode_func decode_func = 0;\n    if (avpkt->size < 8)\n        return AVERROR_INVALIDDATA;\n    info_offset = 0;\n    info_tag    = AV_RL32(src);\n    if (info_tag == MKTAG(\'I\', \'N\', \'F\', \'O\')) {\n        info_offset = AV_RL32(src + 4);\n        if (info_offset > UINT32_MAX - 8 || info_offset + 8 > avpkt->size) {\n            av_log(avctx, AV_LOG_ERROR,\n                   "Invalid INFO header offset: 0x%08"PRIX32" is too large.\\n",\n                   info_offset);\n            return AVERROR_INVALIDDATA;\n        }\n        info_offset += 8;\n        src         += info_offset;\n        av_log(avctx, AV_LOG_DEBUG, "Skipping INFO chunk.\\n");\n    }\n    data_start = src - avpkt->data;\n    data_size  = avpkt->size - data_start;\n    if (data_size < HQX_HEADER_SIZE) {\n        av_log(avctx, AV_LOG_ERROR, "Frame too small.\\n");\n        return AVERROR_INVALIDDATA;\n    }\n    if (src[0] != \'H\' || src[1] != \'Q\') {\n        av_log(avctx, AV_LOG_ERROR, "Not an HQX frame.\\n");\n        return AVERROR_INVALIDDATA;\n    }\n    ctx->interlaced = !(src[2] & 0x80);\n    ctx->format     = src[2] & 7;\n    ctx->dcb        = (src[3] & 3) + 8;\n    ctx->width      = AV_RB16(src + 4);\n    ctx->height     = AV_RB16(src + 6);\n    for (i = 0; i < 17; i++)\n        slice_off[i] = AV_RB24(src + 8 + i * 3);\n    if (ctx->dcb == 8) {\n        av_log(avctx, AV_LOG_ERROR, "Invalid DC precision %d.\\n", ctx->dcb);\n        return AVERROR_INVALIDDATA;\n    }\n    ret = av_image_check_size(ctx->width, ctx->height, 0, avctx);\n    if (ret < 0) {\n        av_log(avctx, AV_LOG_ERROR, "Invalid stored dimenstions %dx%d.\\n",\n               ctx->width, ctx->height);\n        return AVERROR_INVALIDDATA;\n    }\n    avctx->coded_width         = FFALIGN(ctx->width,  16);\n    avctx->coded_height        = FFALIGN(ctx->height, 16);\n    avctx->width               = ctx->width;\n    avctx->height              = ctx->height;\n    avctx->bits_per_raw_sample = 10;\n    switch (ctx->format) {\n    case HQX_422:\n        avctx->pix_fmt = AV_PIX_FMT_YUV422P16;\n        decode_func = hqx_decode_422;\n        break;\n    case HQX_444:\n        avctx->pix_fmt = AV_PIX_FMT_YUV444P16;\n        decode_func = hqx_decode_444;\n        break;\n    case HQX_422A:\n        avctx->pix_fmt = AV_PIX_FMT_YUVA422P16;\n        decode_func = hqx_decode_422a;\n        break;\n    case HQX_444A:\n        avctx->pix_fmt = AV_PIX_FMT_YUVA444P16;\n        decode_func = hqx_decode_444a;\n        break;\n    }\n    if (!decode_func) {\n        av_log(avctx, AV_LOG_ERROR, "Invalid format: %d.\\n", ctx->format);\n        return AVERROR_INVALIDDATA;\n    }\n    ret = ff_get_buffer(avctx, pic, 0);\n    if (ret < 0) {\n        av_log(avctx, AV_LOG_ERROR, "Could not allocate buffer.\\n");\n        return ret;\n    }\n    for (slice = 0; slice < 16; slice++) {\n        if (slice_off[slice] < HQX_HEADER_SIZE ||\n            slice_off[slice] >= slice_off[slice + 1] ||\n            slice_off[slice + 1] > data_size) {\n            av_log(avctx, AV_LOG_ERROR, "Invalid slice size.\\n");\n            break;\n        }\n        ret = init_get_bits(&gb, src + slice_off[slice],\n                            (slice_off[slice + 1] - slice_off[slice]) * 8);\n        if (ret < 0)\n            return ret;\n        ret = decode_slice(ctx, pic, &gb, slice, decode_func);\n        if (ret < 0) {\n            av_log(avctx, AV_LOG_ERROR, "Error decoding slice %d.\\n", slice);\n        }\n    }\n    pic->key_frame = 1;\n    pic->pict_type = AV_PICTURE_TYPE_I;\n    *got_picture_ptr = 1;\n    return avpkt->size;\n}']