Репозиторий Sisyphus
Последнее обновление: 1 октября 2023 | Пакетов: 18631 | Посещений: 37812568
en ru br
Репозитории ALT
S:3.3.11.1-alt2
5.1: 3.1.11-alt0.8
4.1: 3.1.11-alt0.4
4.0: 3.1.11-alt0.2
3.0: 3.1.10-alt3
www.altlinux.org/Changes

Группа :: Система/Библиотеки
Пакет: libmikmod

 Главная   Изменения   Спек   Патчи   Sources   Загрузить   Gear   Bugs and FR  Repocop 

Патч: libmikmod-3.1.12-CVE-2009-0179.patch
Скачать


Index: loaders/load_xm.c
===================================================================
--- loaders/load_xm.c.orig
+++ loaders/load_xm.c
@@ -636,7 +636,8 @@ static BOOL LoadInstruments(void)
 				_mm_fseek(modreader,ck,SEEK_SET);
 				for(u=headend-_mm_ftell(modreader);u;u--) _mm_read_UBYTE(modreader);
 
-				if(_mm_eof(modreader)) {
+				/* last instrument is at the end of file in version 0x0104 */
+				if(_mm_eof(modreader) && (mh->version<0x0104 || t<of.numins-1)) {
 					free(nextwav);free(wh);
 					nextwav=NULL;wh=NULL;
 					_mm_errno = MMERR_LOADING_SAMPLEINFO;
Index: playercode/mloader.c
===================================================================
--- playercode/mloader.c.orig
+++ playercode/mloader.c
@@ -450,10 +450,12 @@ MODULE* Player_LoadGeneric_internal(MREA
 	if (!l->Init || l->Init()) {
 		_mm_rewind(modreader);
 		ok = l->Load(curious);
-		/* propagate inflags=flags for in-module samples */
-		for (t = 0; t < of.numsmp; t++)
-			if (of.samples[t].inflags == 0)
-				of.samples[t].inflags = of.samples[t].flags;
+		if (ok) {
+			/* propagate inflags=flags for in-module samples */
+			for (t = 0; t < of.numsmp; t++)
+				if (of.samples[t].inflags == 0)
+					of.samples[t].inflags = of.samples[t].flags;
+		}
 	} else
 		ok = 0;
 
 
дизайн и разработка: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
текущий майнтейнер: Michael Shigorin