issue 372 - fix Mac OS X minidump generation code to handle x86-64 properly. r=mark at http://breakpad.appspot.com/103001

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@578 4c0a9323-5329-0410-9bdc-e9ce6186880e
This commit is contained in:
ted.mielczarek 2010-04-29 18:02:42 +00:00
parent f2dfb88b2a
commit 131c0c6a83
6 changed files with 54 additions and 17 deletions

View file

@ -56,6 +56,8 @@
#if TARGET_CPU_X86
# define BREAKPAD_MACHINE_THREAD_STATE i386_THREAD_STATE
#elif TARGET_CPU_X86_64
# define BREAKPAD_MACHINE_THREAD_STATE x86_THREAD_STATE64
#else
# define BREAKPAD_MACHINE_THREAD_STATE MACHINE_THREAD_STATE
#endif

View file

@ -71,7 +71,9 @@ int MachoWalker::ValidateCPUType(int cpu_type) {
#if __ppc__
cpu_type = CPU_TYPE_POWERPC;
#elif __i386__
cpu_type = CPU_TYPE_X86;
cpu_type = CPU_TYPE_X86;
#elif __x86_64__
cpu_type = CPU_TYPE_X86_64;
#else
#error Unknown architecture -- are you on a PDP-11?
#endif

View file

@ -55,10 +55,10 @@ std::string ConvertToString(CFStringRef str) {
unsigned int IntegerValueAtIndex(string &str, unsigned int idx) {
string digits("0123456789"), temp;
unsigned int start = 0;
unsigned int end;
unsigned int found = 0;
unsigned int result = 0;
size_t start = 0;
size_t end;
size_t found = 0;
size_t result = 0;
for (; found <= idx; ++found) {
end = str.find_first_not_of(digits, start);