libavcodec/v210enc.c:149: error: Uninitialized Value
  The value read from val was never initialized.

libavcodec/v210enc.c:149:17: 
147.             }
148.             if (w < avctx->width - 3) {
149.                 val |= (CLIP(*u++) << 10) | (CLIP(*y++) << 20);
                     ^
150.                 AV_WL32(dst, val);
151.                 dst += 4;

static int encode_frame(AVCodecContext *avctx, AVPacket *pkt,
                        const AVFrame *pic, int *got_packet)
{
    V210EncContext *s = avctx->priv_data;
    int aligned_width = ((avctx->width + 47) / 48) * 48;
    int stride = aligned_width * 8 / 3;
    int line_padding = stride - ((avctx->width * 8 + 11) / 12) * 4;
    int h, w, ret;
    uint8_t *dst;
    ret = ff_alloc_packet(pkt, avctx->height * stride);
    if (ret < 0) {
        av_log(avctx, AV_LOG_ERROR, "Error getting output packet.\n");
        return ret;
    }
    dst = pkt->data;
    if (pic->format == AV_PIX_FMT_YUV422P10) {
        const uint16_t *y = (const uint16_t *)pic->data[0];
        const uint16_t *u = (const uint16_t *)pic->data[1];
        const uint16_t *v = (const uint16_t *)pic->data[2];
        for (h = 0; h < avctx->height; h++) {
            uint32_t val;
            w = (avctx->width / 6) * 6;
            s->pack_line_10(y, u, v, dst, w);
            y += w;
            u += w >> 1;
            v += w >> 1;
            dst += (w / 6) * 16;
            if (w < avctx->width - 1) {
                WRITE_PIXELS(u, y, v);
                val = CLIP(*y++);
                if (w == avctx->width - 2) {
                    AV_WL32(dst, val);
                    dst += 4;
                }
            }
            if (w < avctx->width - 3) {
                val |= (CLIP(*u++) << 10) | (CLIP(*y++) << 20);
                AV_WL32(dst, val);
                dst += 4;
                val = CLIP(*v++) | (CLIP(*y++) << 10);
                AV_WL32(dst, val);
                dst += 4;
            }
            memset(dst, 0, line_padding);
            dst += line_padding;
            y += pic->linesize[0] / 2 - avctx->width;
            u += pic->linesize[1] / 2 - avctx->width / 2;
            v += pic->linesize[2] / 2 - avctx->width / 2;
        }
    } else if(pic->format == AV_PIX_FMT_YUV422P) {
        const uint8_t *y = pic->data[0];
        const uint8_t *u = pic->data[1];
        const uint8_t *v = pic->data[2];
        for (h = 0; h < avctx->height; h++) {
            uint32_t val;
            w = (avctx->width / 12) * 12;
            s->pack_line_8(y, u, v, dst, w);
            y += w;
            u += w >> 1;
            v += w >> 1;
            dst += (w / 12) * 32;
            for (; w < avctx->width - 5; w += 6) {
                WRITE_PIXELS8(u, y, v);
                WRITE_PIXELS8(y, u, y);
                WRITE_PIXELS8(v, y, u);
                WRITE_PIXELS8(y, v, y);
            }
            if (w < avctx->width - 1) {
                WRITE_PIXELS8(u, y, v);
                val = CLIP8(*y++) << 2;
                if (w == avctx->width - 2) {
                    AV_WL32(dst, val);
                    dst += 4;
                }
            }
            if (w < avctx->width - 3) {
                val |= (CLIP8(*u++) << 12) | (CLIP8(*y++) << 22);
                AV_WL32(dst, val);
                dst += 4;
                val = (CLIP8(*v++) << 2) | (CLIP8(*y++) << 12);
                AV_WL32(dst, val);
                dst += 4;
            }
            memset(dst, 0, line_padding);
            dst += line_padding;
            y += pic->linesize[0] - avctx->width;
            u += pic->linesize[1] - avctx->width / 2;
            v += pic->linesize[2] - avctx->width / 2;
        }
    }
    pkt->flags |= AV_PKT_FLAG_KEY;
    *got_packet = 1;
    return 0;
}
['static int encode_frame(AVCodecContext *avctx, AVPacket *pkt,\n                        const AVFrame *pic, int *got_packet)\n{\n    V210EncContext *s = avctx->priv_data;\n    int aligned_width = ((avctx->width + 47) / 48) * 48;\n    int stride = aligned_width * 8 / 3;\n    int line_padding = stride - ((avctx->width * 8 + 11) / 12) * 4;\n    int h, w, ret;\n    uint8_t *dst;\n    ret = ff_alloc_packet(pkt, avctx->height * stride);\n    if (ret < 0) {\n        av_log(avctx, AV_LOG_ERROR, "Error getting output packet.\\n");\n        return ret;\n    }\n    dst = pkt->data;\n    if (pic->format == AV_PIX_FMT_YUV422P10) {\n        const uint16_t *y = (const uint16_t *)pic->data[0];\n        const uint16_t *u = (const uint16_t *)pic->data[1];\n        const uint16_t *v = (const uint16_t *)pic->data[2];\n        for (h = 0; h < avctx->height; h++) {\n            uint32_t val;\n            w = (avctx->width / 6) * 6;\n            s->pack_line_10(y, u, v, dst, w);\n            y += w;\n            u += w >> 1;\n            v += w >> 1;\n            dst += (w / 6) * 16;\n            if (w < avctx->width - 1) {\n                WRITE_PIXELS(u, y, v);\n                val = CLIP(*y++);\n                if (w == avctx->width - 2) {\n                    AV_WL32(dst, val);\n                    dst += 4;\n                }\n            }\n            if (w < avctx->width - 3) {\n                val |= (CLIP(*u++) << 10) | (CLIP(*y++) << 20);\n                AV_WL32(dst, val);\n                dst += 4;\n                val = CLIP(*v++) | (CLIP(*y++) << 10);\n                AV_WL32(dst, val);\n                dst += 4;\n            }\n            memset(dst, 0, line_padding);\n            dst += line_padding;\n            y += pic->linesize[0] / 2 - avctx->width;\n            u += pic->linesize[1] / 2 - avctx->width / 2;\n            v += pic->linesize[2] / 2 - avctx->width / 2;\n        }\n    } else if(pic->format == AV_PIX_FMT_YUV422P) {\n        const uint8_t *y = pic->data[0];\n        const uint8_t *u = pic->data[1];\n        const uint8_t *v = pic->data[2];\n        for (h = 0; h < avctx->height; h++) {\n            uint32_t val;\n            w = (avctx->width / 12) * 12;\n            s->pack_line_8(y, u, v, dst, w);\n            y += w;\n            u += w >> 1;\n            v += w >> 1;\n            dst += (w / 12) * 32;\n            for (; w < avctx->width - 5; w += 6) {\n                WRITE_PIXELS8(u, y, v);\n                WRITE_PIXELS8(y, u, y);\n                WRITE_PIXELS8(v, y, u);\n                WRITE_PIXELS8(y, v, y);\n            }\n            if (w < avctx->width - 1) {\n                WRITE_PIXELS8(u, y, v);\n                val = CLIP8(*y++) << 2;\n                if (w == avctx->width - 2) {\n                    AV_WL32(dst, val);\n                    dst += 4;\n                }\n            }\n            if (w < avctx->width - 3) {\n                val |= (CLIP8(*u++) << 12) | (CLIP8(*y++) << 22);\n                AV_WL32(dst, val);\n                dst += 4;\n                val = (CLIP8(*v++) << 2) | (CLIP8(*y++) << 12);\n                AV_WL32(dst, val);\n                dst += 4;\n            }\n            memset(dst, 0, line_padding);\n            dst += line_padding;\n            y += pic->linesize[0] - avctx->width;\n            u += pic->linesize[1] - avctx->width / 2;\n            v += pic->linesize[2] - avctx->width / 2;\n        }\n    }\n    pkt->flags |= AV_PKT_FLAG_KEY;\n    *got_packet = 1;\n    return 0;\n}']