SF.net SVN: tex2rtf:[74] trunk/src
Status: Beta
Brought to you by:
pstieber
From: <pst...@us...> - 2013-11-20 05:35:20
|
Revision: 74 http://sourceforge.net/p/tex2rtf/code/74 Author: pstieber Date: 2013-11-20 05:35:16 +0000 (Wed, 20 Nov 2013) Log Message: ----------- 1. Fixed BigBuffer deletes by adding square brackets. 2. Fixed wxSnprintf usage by adding constants that indicate the size of wxChar buffers const size_t bufSize = N; wxChar buf[bufSize]; wxSnprintf(buf, bufSize, ... instead of using sizeof wxChar buf[N]; wxSnprintf(buf, sizeof(buf), ... to prevent a write past the end of the wxChar buffer. The wxSnprintf function writes a null character at the end of the buffer to guarantee data that is too long is terminated. Since wxChar represents Unicode strings that are 2 bytes and sizeof(buf) returns the number of characters not elements in the wxChar buffer, the null was placed past the end of the array. Modified Paths: -------------- trunk/src/bmputils.h trunk/src/htmlutil.cpp trunk/src/rtfutils.cpp trunk/src/table.cpp trunk/src/tex2any.cpp trunk/src/tex2rtf.cpp trunk/src/texutils.cpp This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |