From 6c571dfe17dece289360b9008d19be522e31bab8 Mon Sep 17 00:00:00 2001
From: Fredrik Mellbin <fredrik.mellbin@gmail.com>
Date: Wed, 1 Oct 2008 19:29:42 +0000
Subject: [PATCH] todo stuff

Originally committed to SVN as r2405.
---
 FFmpegSource2/ffavsfilters.cpp | 2 +-
 FFmpegSource2/indexing.cpp     | 5 +++--
 2 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/FFmpegSource2/ffavsfilters.cpp b/FFmpegSource2/ffavsfilters.cpp
index 65866aad5..5e005ce7f 100644
--- a/FFmpegSource2/ffavsfilters.cpp
+++ b/FFmpegSource2/ffavsfilters.cpp
@@ -60,7 +60,7 @@ AVSValue __cdecl CreateFFIndex(AVSValue Args, void* UserData, IScriptEnvironment
 	// 1: Index generated
 	// 2: Index forced to be overwritten
 
-	FrameIndex *Index;
+	FrameIndex *Index = NULL;
 	if (OverWrite || !(Index = FFMS_ReadIndex(CacheFile, ErrorMsg, MsgSize))) {
 		if (!(Index = FFMS_MakeIndex(Source, IndexMask, DumpMask, AudioFile, true, NULL, NULL, ErrorMsg, MsgSize)))
 			Env->ThrowError("FFIndex: %s", ErrorMsg);
diff --git a/FFmpegSource2/indexing.cpp b/FFmpegSource2/indexing.cpp
index 44c3e8aea..0570c090c 100644
--- a/FFmpegSource2/indexing.cpp
+++ b/FFmpegSource2/indexing.cpp
@@ -66,8 +66,9 @@ public:
 
 	~FFAudioContext() {
 		delete W64W;
-		if (CTX)
-			avcodec_close(CTX);
+//		FIXME, why is there an access violation here?
+//		if (CTX)
+//			avcodec_close(CTX);
 	}
 };
 
-- 
GitLab