diff options
author | ladderbreaker <ladderbreaker@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2007-07-03 00:09:14 +0000 |
---|---|---|
committer | ladderbreaker <ladderbreaker@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2007-07-03 00:09:14 +0000 |
commit | 43a81daaba1f02eab50e2d0283f03b8ad45bf570 (patch) | |
tree | 4e45a1251735c165ed02fd84c860896723ba8f3b /src/client | |
parent | These should be int to allow them to be ORed together. Ted, please review. (diff) | |
download | breakpad-43a81daaba1f02eab50e2d0283f03b8ad45bf570.tar.xz |
issue 194: reviewed by waylonis
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@195 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src/client')
-rw-r--r-- | src/client/mac/handler/dynamic_images.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/client/mac/handler/dynamic_images.h b/src/client/mac/handler/dynamic_images.h index 497f4eb4..4c4ab7ff 100644 --- a/src/client/mac/handler/dynamic_images.h +++ b/src/client/mac/handler/dynamic_images.h @@ -158,8 +158,9 @@ class DynamicImage { // Makes local copy of file path to mach-o binary void InitializeFilePath(char *inFilePath) { if (inFilePath) { - file_path_ = reinterpret_cast<char*>(malloc(strlen(inFilePath))); - strcpy(file_path_, inFilePath); + size_t path_size = 1 + strlen(inFilePath); + file_path_ = reinterpret_cast<char*>(malloc(path_size)); + strlcpy(file_path_, inFilePath, path_size); } else { file_path_ = NULL; } |