diff options
Diffstat (limited to 'src/client/mac/crash_generation')
-rw-r--r-- | src/client/mac/crash_generation/Inspector.mm | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/client/mac/crash_generation/Inspector.mm b/src/client/mac/crash_generation/Inspector.mm index d328ee5d..1fe2a208 100644 --- a/src/client/mac/crash_generation/Inspector.mm +++ b/src/client/mac/crash_generation/Inspector.mm @@ -44,6 +44,8 @@ #import "common/mac/SimpleStringDictionary.h" #import "common/mac/MachIPC.h" +#import "GTMDefines.h" + #import <Foundation/Foundation.h> #if VERBOSE @@ -91,14 +93,14 @@ static BOOL EnsureDirectoryPathExists(NSString *dirPath) { // Break up the difference into components NSString *diff = [dirPath substringFromIndex:[common length] + 1]; NSArray *components = [diff pathComponents]; - unsigned count = [components count]; + NSUInteger count = [components count]; // Rebuild the path one component at a time NSDictionary *attrs = [NSDictionary dictionaryWithObject:[NSNumber numberWithUnsignedLong:0750] forKey:NSFilePosixPermissions]; path = common; - for (unsigned i = 0; i < count; ++i) { + for (NSUInteger i = 0; i < count; ++i) { path = [path stringByAppendingPathComponent:[components objectAtIndex:i]]; if (![mgr createDirectoryAtPath:path attributes:attrs]) @@ -329,7 +331,6 @@ kern_return_t Inspector::ReadMessages() { // we are expected to read. // Read each key/value pair, one mach message per key/value pair. for (unsigned int i = 0; i < info.parameter_count; ++i) { - MachReceiveMessage message; result = receive_port.WaitForMessage(&message, 1000); if(result == KERN_SUCCESS) { @@ -376,11 +377,11 @@ void Inspector::SetCrashTimeParameters() { if (processStartTimeString) { time_t processStartTime = strtol(processStartTimeString, NULL, 10); time_t processUptime = tv.tv_sec - processStartTime; - sprintf(processUptimeString, "%d", processUptime); + sprintf(processUptimeString, "%zd", processUptime); config_params_.SetKeyValue(BREAKPAD_PROCESS_UP_TIME, processUptimeString); } - sprintf(processCrashtimeString, "%d", tv.tv_sec); + sprintf(processCrashtimeString, "%zd", tv.tv_sec); config_params_.SetKeyValue(BREAKPAD_PROCESS_CRASH_TIME, processCrashtimeString); } |