X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/eafc087e69e52add5952190bfd5bcbbf931ad12b..447daba1ce4295f84185d6ecdaec46ae982a2299:/src/common/datstrm.cpp diff --git a/src/common/datstrm.cpp b/src/common/datstrm.cpp index c79eedb07a..17f2100ebe 100644 --- a/src/common/datstrm.cpp +++ b/src/common/datstrm.cpp @@ -190,8 +190,8 @@ void wxDataStream::WriteString(const wxString& string) if (!m_ostream) return; - Write32(tmp_string.Length()); - m_ostream->write((const char *) tmp_string, tmp_string.Length()); + Write32(string.Length()); + m_ostream->write((const char *) string, string.Length()); } // Must be at global scope for VC++ 5 @@ -204,6 +204,11 @@ void wxDataStream::WriteDouble(double d) if (!m_ostream) return; +#if USE_APPLE_IEEE ConvertToIeeeExtended(d, (unsigned char *)buf); +#else +# pragma warning "wxDataStream::WriteDouble() not using IeeeExtended - will not work!" + buf[0] = '\0'; +#endif m_ostream->write(buf, 10); }