Originally committed as revision 18360 to svn://svn.ffmpeg.org/ffmpeg/trunk
Unified · Split
| @@ -226,7 +226,8 @@ static int nuv_packet(AVFormatContext *s, AVPacket *pkt) { · 225 unmodified lines | |||
| 226 | pkt->stream_index = ctx->v_id; | 226 | pkt->stream_index = ctx->v_id; |
| 227 | memcpy(pkt->data, hdr, copyhdrsize); | 227 | memcpy(pkt->data, hdr, copyhdrsize); |
| 228 | ret = get_buffer(pb, pkt->data + copyhdrsize, size); | 228 | ret = get_buffer(pb, pkt->data + copyhdrsize, size); |
| 229 | return ret; | 229 | if (ret < 0) return ret; |
| 230 | return 0; | ||
| 230 | case NUV_AUDIO: | 231 | case NUV_AUDIO: |
| 231 | if (ctx->a_id < 0) { | 232 | if (ctx->a_id < 0) { |
| 232 | av_log(s, AV_LOG_ERROR, "Audio packet in file without audio stream!\n"); | 233 | av_log(s, AV_LOG_ERROR, "Audio packet in file without audio stream!\n"); |
| @@ -238,7 +239,8 @@ static int nuv_packet(AVFormatContext *s, AVPacket *pkt) { · 5 unmodified lines | |||
| 238 | pkt->pos = pos; | 239 | pkt->pos = pos; |
| 239 | pkt->pts = AV_RL32(&hdr[4]); | 240 | pkt->pts = AV_RL32(&hdr[4]); |
| 240 | pkt->stream_index = ctx->a_id; | 241 | pkt->stream_index = ctx->a_id; |
| 241 | return ret; | 242 | if (ret < 0) return ret; |
| 243 | return 0; | ||
| 242 | case NUV_SEEKP: | 244 | case NUV_SEEKP: |
| 243 | // contains no data, size value is invalid | 245 | // contains no data, size value is invalid |
| 244 | break; | 246 | break; |