test/encode/avcenc: Wait upload thread exiting before release driver resource.
authorZhou Chang <chang.zhou@intel.com>
Fri, 29 Jul 2011 01:15:10 +0000 (09:15 +0800)
committerXiang, Haihao <haihao.xiang@intel.com>
Tue, 28 May 2013 08:46:48 +0000 (16:46 +0800)
Signed-off-by: Zhou Chang <chang.zhou@intel.com>
test/encode/avcenc.c

index 49c1187..5a861d7 100644 (file)
@@ -256,6 +256,7 @@ static void alloc_encode_resource(FILE *yuv_fp)
 
 static void release_encode_resource()
 {
+    pthread_join(avcenc_context.upload_thread_id, NULL);
     free(newImageBuffer);
 
     // Release all the surfaces resource