Commits

Michael Ziegler committed 48a6992

if the codec doesn't return a frame, raise DecodeError

Comments (0)

Files changed (1)

myffmpeg/ffmpegmodule.c

 	av_free_packet(&avpkt);
 	
 	if (got_frame == 0) {
+		PyErr_SetString(FfmpegDecodeError, "codec didn't get a frame");
 		av_free(avfrm);
-		return Py_BuildValue( "s", "" );
+		return NULL;
 	}
 	
 	data_size = av_samples_get_buffer_size(