Index: third_party/crashpad/crashpad/snapshot/win/process_snapshot_win.cc |
diff --git a/third_party/crashpad/crashpad/snapshot/win/process_snapshot_win.cc b/third_party/crashpad/crashpad/snapshot/win/process_snapshot_win.cc |
index 7a18dbef417025213e0d9ac3f6eea58a0a2a8f33..11df2b803cb27d37c7a43756dd1b34bc8e08c65e 100644 |
--- a/third_party/crashpad/crashpad/snapshot/win/process_snapshot_win.cc |
+++ b/third_party/crashpad/crashpad/snapshot/win/process_snapshot_win.cc |
@@ -15,6 +15,7 @@ |
#include "snapshot/win/process_snapshot_win.h" |
#include <stddef.h> |
+#include <wchar.h> |
#include <algorithm> |
@@ -325,8 +326,9 @@ void ProcessSnapshotWin::InitializeUnloadedModules() { |
uet.SizeOfImage, |
uet.CheckSum, |
uet.TimeDateStamp, |
- base::UTF16ToUTF8( |
- base::StringPiece16(uet.ImageName, arraysize(uet.ImageName))))); |
+ base::UTF16ToUTF8(base::StringPiece16( |
+ uet.ImageName, |
+ wcsnlen(uet.ImageName, arraysize(uet.ImageName)))))); |
} |
} |
} |