comments written to minidump file as ANSI string
[public/netxms.git] / src / libnetxms / seh.cpp
index d37709e..d9d81fa 100644 (file)
@@ -344,11 +344,11 @@ BOOL LIBNETXMS_EXPORTABLE SEHServiceExceptionHandler(EXCEPTION_POINTERS *pInfo)
                mei.ExceptionPointers = pInfo;
                mei.ClientPointers = FALSE;
 
-      static const TCHAR *comments = _T("Version: ") NETXMS_VERSION_STRING _T("\nBuild tag: ") NETXMS_BUILD_TAG;
+      static const char *comments = "Version=" NETXMS_VERSION_STRING_A "; BuildTag=" NETXMS_BUILD_TAG_A;
       MINIDUMP_USER_STREAM us;
-      us.Type = CommentStreamW;
+      us.Type = CommentStreamA;
       us.Buffer = (void*)comments;
-      us.BufferSize = static_cast<ULONG>(_tcslen(comments) * sizeof(TCHAR));
+      us.BufferSize = static_cast<ULONG>(strlen(comments) + 1);
 
       MINIDUMP_USER_STREAM_INFORMATION usi;
       usi.UserStreamCount = 1;