]> granicus.if.org Git - handbrake/commitdiff
Fix a Segfault (attempt 2) where the job struct is used after it's closed.
authorsr55 <sr55.hb@outlook.com>
Thu, 12 Dec 2013 19:00:15 +0000 (19:00 +0000)
committersr55 <sr55.hb@outlook.com>
Thu, 12 Dec 2013 19:00:15 +0000 (19:00 +0000)
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@5928 b64f7644-9d1e-0410-96f1-a4d463321fa5

libhb/work.c

index 02a57c0699fbfea803ec35c6ee9c412253ae3ebe..e76c88a91a0d89a481d73ceda10f6d98e74d7a0c 100644 (file)
@@ -1614,14 +1614,15 @@ cleanup:
             }
         }
     }
-    
+
+    hb_buffer_pool_free();
+          
     /* OpenCL: must be closed *after* freeing the buffer pool */
     if (job->use_opencl)
     {
         hb_ocl_close();
     }
-
-    hb_buffer_pool_free();
+    
     hb_job_close( &job );
 }