From 1e2aca6e4997a7e4dd1e727871d933f4954bd2b6 Mon Sep 17 00:00:00 2001 From: Laurent Gomila Date: Fri, 19 Aug 2011 18:28:21 +0200 Subject: [PATCH] Fixed sf::Texture copy constructor --- src/SFML/Graphics/Texture.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/SFML/Graphics/Texture.cpp b/src/SFML/Graphics/Texture.cpp index 9e4cdbca..b7a80d33 100644 --- a/src/SFML/Graphics/Texture.cpp +++ b/src/SFML/Graphics/Texture.cpp @@ -61,7 +61,8 @@ myTexture (0), myIsSmooth (copy.myIsSmooth), myPixelsFlipped(false) { - LoadFromImage(copy.CopyToImage()); + if (copy.myTexture) + LoadFromImage(copy.CopyToImage()); }