summaryrefslogtreecommitdiffstats
path: root/src/3rdparty/patches/libmng-1.0.10-endless-loop.patch
diff options
context:
space:
mode:
Diffstat (limited to 'src/3rdparty/patches/libmng-1.0.10-endless-loop.patch')
-rw-r--r--src/3rdparty/patches/libmng-1.0.10-endless-loop.patch65
1 files changed, 65 insertions, 0 deletions
diff --git a/src/3rdparty/patches/libmng-1.0.10-endless-loop.patch b/src/3rdparty/patches/libmng-1.0.10-endless-loop.patch
new file mode 100644
index 0000000..31f0474
--- /dev/null
+++ b/src/3rdparty/patches/libmng-1.0.10-endless-loop.patch
@@ -0,0 +1,65 @@
+--- libmng_data.h.orig 2007-04-20 10:41:58.000000000 +0200
++++ libmng_data.h 2007-07-14 00:00:00.000000000 +0200
+@@ -658,6 +658,9 @@
+ mng_int32 iFrameclipb;
+
+ mng_uint32 iNextdelay; /* delay *after* next image */
++
++ mng_bool bForcedelay;
++ mng_uint32 iAccumdelay;
+ #endif
+
+ #ifndef MNG_SKIPCHUNK_SHOW
+--- libmng_display.c.orig 2007-04-20 10:41:58.000000000 +0200
++++ libmng_display.c 2007-07-14 00:00:00.000000000 +0200
+@@ -384,8 +384,9 @@
+
+ {
+ #ifndef MNG_SKIPCHUNK_FRAM
+- if (pData->iFramedelay > 0) /* real delay ? */
++ if (pData->iFramedelay > 0 || pData->bForcedelay) /* real delay ? */
+ { /* let the app refresh first ? */
++ pData->bForcedelay = MNG_FALSE;
+ if ((pData->bRunning) && (!pData->bSkipping) &&
+ (pData->iUpdatetop < pData->iUpdatebottom) && (pData->iUpdateleft < pData->iUpdateright))
+ if (!pData->fRefresh (((mng_handle)pData),
+@@ -455,6 +456,7 @@
+ pData->iFrametime = pData->iFrametime + iWaitfor;
+ /* setup for next delay */
+ pData->iFramedelay = pData->iNextdelay;
++ pData->iAccumdelay += pData->iFramedelay;
+ #endif
+ }
+
+@@ -3340,6 +3342,9 @@
+ MNG_TRACE (pData, MNG_FN_PROCESS_DISPLAY_MEND, MNG_LC_START);
+ #endif
+
++ pData->bForcedelay = pData->iAccumdelay ? MNG_FALSE : MNG_TRUE;
++ pData->iAccumdelay = 0;
++
+ #ifdef MNG_SUPPORT_DYNAMICMNG
+ if (pData->bStopafterseek) /* need to stop after this ? */
+ {
+--- libmng_hlapi.c.orig 2007-07-06 18:23:04.000000000 +0200
++++ libmng_hlapi.c 2007-07-14 00:00:00.000000000 +0200
+@@ -446,6 +446,9 @@
+ pData->iFrameclipb = 0;
+
+ pData->iNextdelay = 1;
++
++ pData->bForcedelay = MNG_FALSE;
++ pData->iAccumdelay = 0;
+ #endif
+
+ #ifndef MNG_SKIPCHUNK_SHOW
+@@ -1737,6 +1740,9 @@
+ pData->iFrameclipb = 0;
+
+ pData->iNextdelay = 1;
++
++ pData->bForcedelay = MNG_FALSE;
++ pData->iAccumdelay = 0;
+ #endif
+
+ #ifndef MNG_SKIPCHUNK_SHOW