Explorar o código

do not add the post_sync task if there is none. Fixes acquiring a data whose consistency flag is cleared

Samuel Thibault %!s(int64=12) %!d(string=hai) anos
pai
achega
f2fffd0544
Modificáronse 1 ficheiros con 2 adicións e 1 borrados
  1. 2 1
      src/datawizard/user_interactions.c

+ 2 - 1
src/datawizard/user_interactions.c

@@ -75,7 +75,8 @@ static void _starpu_data_acquire_fetch_data_callback(void *arg)
 	 * We enqueue the "post" sync task in the list associated to the handle
 	 * so that it is submitted by the starpu_data_release
 	 * function. */
-	_starpu_add_post_sync_tasks(wrapper->post_sync_task, handle);
+	if (wrapper->post_sync_task)
+		_starpu_add_post_sync_tasks(wrapper->post_sync_task, handle);
 
 	wrapper->callback(wrapper->callback_arg);