Index: libs/libmythtv/mpeg/pespacket.cpp
===================================================================
--- libs/libmythtv/mpeg/pespacket.cpp	(revision 9336)
+++ libs/libmythtv/mpeg/pespacket.cpp	(working copy)
@@ -174,7 +174,7 @@
     alloc188.erase(ptr);
     free188.push_back(ptr);
     // free the allocator only if more than 1 block was used
-    if (mem188.size() > 1)
+    if (alloc188.size() == 0 && mem188.size() > 1)
     {
         vector<unsigned char*>::iterator it;
         for (it = mem188.begin(); it != mem188.end(); ++it)
@@ -232,7 +232,7 @@
 #endif 
 
     // free the allocator only if more than 1 block was used
-    if (mem4096.size() > 1)
+    if (alloc4096.size() == 0 && mem4096.size() > 1)
     {
         vector<unsigned char*>::iterator it;
         for (it = mem4096.begin(); it != mem4096.end(); ++it)
