aboutsummaryrefslogtreecommitdiff
path: root/src/tools/linux/md2core/minidump-2-core.cc
diff options
context:
space:
mode:
authorthestig@chromium.org <thestig@chromium.org@4c0a9323-5329-0410-9bdc-e9ce6186880e>2011-10-20 18:23:01 +0000
committerthestig@chromium.org <thestig@chromium.org@4c0a9323-5329-0410-9bdc-e9ce6186880e>2011-10-20 18:23:01 +0000
commit11582abc270028b448a49ab97459bfacd958dd2a (patch)
tree68df807c1613a5f8a159c53512c8fac9389ac3a6 /src/tools/linux/md2core/minidump-2-core.cc
parent Correct incorrect bounds checking. (diff)
downloadbreakpad-11582abc270028b448a49ab97459bfacd958dd2a.tar.xz
Fix some shadow variables, including one in file_id.cc that causes all files to generate the same hash. Add a test to make sure this doesn't happen again.
Review URL: http://breakpad.appspot.com/316002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@875 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src/tools/linux/md2core/minidump-2-core.cc')
-rw-r--r--src/tools/linux/md2core/minidump-2-core.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/tools/linux/md2core/minidump-2-core.cc b/src/tools/linux/md2core/minidump-2-core.cc
index f08da768..efec22e4 100644
--- a/src/tools/linux/md2core/minidump-2-core.cc
+++ b/src/tools/linux/md2core/minidump-2-core.cc
@@ -442,7 +442,7 @@ ParseSystemInfo(CrashedProcess* crashinfo, MMappedRange range,
#else
#error "This code has not been ported to your platform yet"
#endif
- if (!strstr(full_file.GetString(sysinfo->csd_version_rva).c_str(), "Linux")){
+ if (!strstr(full_file.GetString(sysinfo->csd_version_rva).c_str(), "Linux")) {
fprintf(stderr, "This minidump was not generated by Linux.\n");
_exit(1);
}
@@ -654,9 +654,9 @@ ParseCmdLine(CrashedProcess* crashinfo, MMappedRange range) {
len = range.length() > args_len ? args_len : range.length();
memcpy(crashinfo->prps.pr_psargs, cmdline, len);
- for (unsigned i = 0; i < len; ++i) {
- if (crashinfo->prps.pr_psargs[i] == 0)
- crashinfo->prps.pr_psargs[i] = ' ';
+ for (unsigned j = 0; j < len; ++j) {
+ if (crashinfo->prps.pr_psargs[j] == 0)
+ crashinfo->prps.pr_psargs[j] = ' ';
}
break;
}