diff options
Diffstat (limited to 'linden/indra/win_crash_logger')
-rw-r--r-- | linden/indra/win_crash_logger/win_crash_logger.cpp | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/linden/indra/win_crash_logger/win_crash_logger.cpp b/linden/indra/win_crash_logger/win_crash_logger.cpp index a227faf..ddfca5e 100644 --- a/linden/indra/win_crash_logger/win_crash_logger.cpp +++ b/linden/indra/win_crash_logger/win_crash_logger.cpp | |||
@@ -200,7 +200,8 @@ int APIENTRY WinMain(HINSTANCE hInstance, | |||
200 | { | 200 | { |
201 | i++; | 201 | i++; |
202 | 202 | ||
203 | mbstowcs(gProductName, argv[i], sizeof(gProductName)); | 203 | mbstowcs(gProductName, argv[i], sizeof(gProductName)/sizeof(gProductName[0])); |
204 | gProductName[ sizeof(gProductName)/sizeof(gProductName[0]) - 1 ] = 0; | ||
204 | llinfos << "Got product name " << argv[i] << llendl; | 205 | llinfos << "Got product name " << argv[i] << llendl; |
205 | } | 206 | } |
206 | } | 207 | } |
@@ -389,6 +390,7 @@ class LLFileEncoder | |||
389 | { | 390 | { |
390 | public: | 391 | public: |
391 | LLFileEncoder(const char *formname, const char *filename); | 392 | LLFileEncoder(const char *formname, const char *filename); |
393 | ~LLFileEncoder(); | ||
392 | 394 | ||
393 | BOOL isValid() const { return mIsValid; } | 395 | BOOL isValid() const { return mIsValid; } |
394 | LLString encodeURL(const S32 max_length = 0); | 396 | LLString encodeURL(const S32 max_length = 0); |
@@ -837,6 +839,15 @@ LLFileEncoder::LLFileEncoder(const char *form_name, const char *filename) | |||
837 | mIsValid = TRUE; | 839 | mIsValid = TRUE; |
838 | } | 840 | } |
839 | 841 | ||
842 | LLFileEncoder::~LLFileEncoder() | ||
843 | { | ||
844 | if (mBuf) | ||
845 | { | ||
846 | delete mBuf; | ||
847 | mBuf = NULL; | ||
848 | } | ||
849 | } | ||
850 | |||
840 | LLString LLFileEncoder::encodeURL(const S32 max_length) | 851 | LLString LLFileEncoder::encodeURL(const S32 max_length) |
841 | { | 852 | { |
842 | LLString result = mFormname; | 853 | LLString result = mFormname; |