mirror of
https://github.com/yuzu-emu/breakpad.git
synced 2024-10-20 01:58:21 +02:00
issue 194: reviewed by waylonis
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@195 4c0a9323-5329-0410-9bdc-e9ce6186880e
This commit is contained in:
parent
3c07b28119
commit
43a81daaba
@ -158,8 +158,9 @@ class DynamicImage {
|
|||||||
// Makes local copy of file path to mach-o binary
|
// Makes local copy of file path to mach-o binary
|
||||||
void InitializeFilePath(char *inFilePath) {
|
void InitializeFilePath(char *inFilePath) {
|
||||||
if (inFilePath) {
|
if (inFilePath) {
|
||||||
file_path_ = reinterpret_cast<char*>(malloc(strlen(inFilePath)));
|
size_t path_size = 1 + strlen(inFilePath);
|
||||||
strcpy(file_path_, inFilePath);
|
file_path_ = reinterpret_cast<char*>(malloc(path_size));
|
||||||
|
strlcpy(file_path_, inFilePath, path_size);
|
||||||
} else {
|
} else {
|
||||||
file_path_ = NULL;
|
file_path_ = NULL;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user