]> git.saurik.com Git - wxWidgets.git/blobdiff - src/richtext/richtextbuffer.cpp
use renderer for drawing the item background on ports other than GTK2 and Mac too...
[wxWidgets.git] / src / richtext / richtextbuffer.cpp
index 3b3e0e03865f3fbd809c29a2e14a164ef71a9b31..8c75c513df080610d2092c8579a5c5a0496d946f 100644 (file)
@@ -7588,7 +7588,10 @@ bool wxRichTextImageBlock::ReadHex(wxInputStream& stream, int length, wxBitmapTy
     if (m_data)
         delete[] m_data;
 
     if (m_data)
         delete[] m_data;
 
-    wxChar str[2];
+    // create a null terminated temporary string:
+    char str[3];
+    str[2] = '\0';
+
     m_data = new unsigned char[dataSize];
     int i;
     for (i = 0; i < dataSize; i ++)
     m_data = new unsigned char[dataSize];
     int i;
     for (i = 0; i < dataSize; i ++)