From 096ea72fb60aae0fb1f5b207d2072a4b77baaba1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Leclercq?= Date: Wed, 22 Feb 2017 13:00:05 +0100 Subject: [PATCH] Physics2D/PhysWorld2D: Fix crash with physics callbacks --- src/Nazara/Physics2D/PhysWorld2D.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Nazara/Physics2D/PhysWorld2D.cpp b/src/Nazara/Physics2D/PhysWorld2D.cpp index 16ead3332..7c15beee3 100644 --- a/src/Nazara/Physics2D/PhysWorld2D.cpp +++ b/src/Nazara/Physics2D/PhysWorld2D.cpp @@ -72,7 +72,7 @@ namespace Nz { auto it = m_callbacks.emplace(handler, std::make_unique(callbacks)).first; - handler->userData = &it->second; + handler->userData = it->second.get(); if (callbacks.startCallback) {