我刚刚将我的MAC bookpro升级为MAC Yosemite。 当我尝试安装一个基本上是在Xcode 3.2.6上构建的应用程序时,它已经崩溃了。我不确定崩溃是否适用于3.2.6或其他类似的代码。 我知道在Xcode 3.2.6和10.4u SDK中开发了Yosemite和app的有点旧组合,但我们需要这样做。 我收集了崩溃日志,看起来如下。任何人都可以告诉我崩溃日志中的确切问题是什么?我无法解密此崩溃日志的含义。如果有人打电话给我发生什么事情对我来说会很有帮助
另一个信息是,当我尝试在yosemite上安装Xcode 3.2.6和10.4u时,它安装但XCode应用程序符号被阻止,我无法启动xcode本身。还需要有关此的建议
先谢谢, Saravana
Process: CCAAgent [282]
Path: /Applications/CCAAgent.app/Contents/MacOS/CCAAgent
Identifier: com.cisco.cca.CCAAgent
Version: 4.9.5.1
Code Type: X86 (Native)
Parent Process: ??? [1]
Responsible: CCAAgent [282]
User ID: 501
Date/Time: 2014-07-24 22:29:34.747 +0530
OS Version: Mac OS X 10.10 (14A238x)
Report Version: 11
Anonymous UUID: 2C41B0C2-75AC-0B5D-6435-99E4F7DF5556
Time Awake Since Boot: 110 seconds
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: KERN_INVALID_ADDRESS at 0x0000000088fa4000
VM Regions Near 0x88fa4000:
MALLOC_LARGE 0000000008fa3000-0000000088fa4000 [ 2.0G] rw-/rwx SM=PRV
-->
__TEXT 000000008fe1f000-000000008fe53000 [ 208K] r-x/rwx SM=COW /usr/lib/dyld
Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0 libsystem_platform.dylib 0x963511b0 _platform_memmove$VARIANT$sse42 + 192
1 com.apple.CoreFoundation 0x928261e2 __CFStringCreateImmutableFunnel3 + 3010
2 com.apple.CoreFoundation 0x928406df CFStringCreateWithSubstring + 495
3 com.apple.CoreFoundation 0x9289a173 -[__NSCFString substringWithRange:] + 307
4 com.cisco.cca.CCAAgent 0x00016bb2 +[CCALog getThreadNumber:] + 145
5 com.cisco.cca.CCAAgent 0x00017173 +[CCALog createLogFromSourceCode:lineNumber:withLevel:withPrivacy:andStringFormat:] + 446
6 com.cisco.cca.CCAAgent 0x00028cfa GetMacOSVersionString + 211
7 com.cisco.cca.CCAAgent 0x00015965 -[AppMainController init] + 79
8 com.apple.AppKit 0x9a141e06 -[NSCustomObject nibInstantiate] + 380
9 com.apple.AppKit 0x9a141c18 -[NSIBObjectData instantiateObject:] + 319
10 com.apple.AppKit 0x9a68d29f -[NSIBObjectData nibInstantiateWithOwner:options:topLevelObjects:] + 450`enter code here`
11 com.apple.AppKit 0x9a141237 -[NSIBObjectData nibInstantiateWithOwner:topLevelObjects:] + 56
12 com.apple.AppKit 0x9a13513e loadNib + 462
13 com.apple.AppKit 0x9a72dcf6 +[NSBundle(NSNibLoading) _loadNibFile:nameTable:options:withZone:ownerBundle:] + 330
14 com.apple.AppKit 0x9a72e4e2 +[NSBundle(NSNibLoadingInternal) _loadNibFile:externalNameTable:options:withZone:] + 161
15 com.apple.AppKit 0x9a3922af +[NSBundle(NSNibLoading) loadNibFile:externalNameTable:withZone:] + 67
16 com.apple.AppKit 0x9a1345e2 +[NSBundle(NSNibLoading) loadNibNamed:owner:] + 745
17 com.apple.AppKit 0x9a12fbe0 NSApplicationMain + 690
18 com.cisco.cca.CCAAgent 0x000036fa main + 470
19 com.cisco.cca.CCAAgent 0x000032ee _start + 216
20 com.cisco.cca.CCAAgent 0x00003215 start + 41
============================
#import <Cocoa/Cocoa.h>
#import <stdlib.h>
#import <time.h>
#import "RC4.h"
#define NSLogSecuredString(level,s,...) [CCALog createLogFromSourceCode:__FILE__ lineNumber:__LINE__ withLevel:level withPrivacy:LOG_PRIVACY_ENCRYPTED andStringFormat:(s),##__VA_ARGS__]
#define NSLogSecuredString(level,s,...) [CCALog createLogFromSourceCode:__FILE__ lineNumber:__LINE__ withLevel:level withPrivacy:LOG_PRIVACY_ENCRYPTED andStringFormat:(s),##__VA_ARGS__]
#define LOG_LEVEL_ALL 10
#define LOG_LEVEL_DEBUG 100 // Debug info
#define LOG_LEVEL_WARN 200 // Warning info
#define LOG_LEVEL_ERROR 300 // Error info
#define LOG_LEVEL_INFO 1000 // System information
#define LOG_PRIVACY_CLEARTEXT 1 // Log is in clear text
#define LOG_PRIVACY_ENCRYPTED 2 // Log is encrypted
@interface CCALog : NSObject
{
}
+ (void)initialize;
+ (void)setAcceptLogLevel:(NSString*)newLogLevelString withEncryptedLogFilePath:(const char*)encryptedLogPath;
+ (void)setMaxLogSize:(int)newMaxLogSize;
+ (void)dealloc;
+ (int)m_CurrentLogLevel;
+ (void)setCurrentLogLevel:(int)newLogLevel;
+ (void)createLogFromSourceCode:(char*)sourceFile lineNumber:(int)lineNumber withLevel:(int)level withPrivacy:(int)privacy andStringFormat:(const char *)format, ...;
@end
//=====================================================================================================================
// Get the current thread number
//=====================================================================================================================
+ (NSInteger)getThreadNumber:(NSThread*)thread
{
NSString* threadString;
NSRange numRange;
NSUInteger numLength;
// Somehow there doesn't seem to be an listOfArgumentsI call to return the
// threadnumber only the name of the thread can be returned but this is NULL
// if it is not set first!
// Here is a bit of code to extract the thread number out of the string
// an NSThread returns when you ask its description to be printed out
// by NSLog. The format looks like:
// <NSThread: 0x10113a0>{name = (null), num = 1}
// Basically I search for the "num = " substring, copy the remainder
// excluding the '}' which gives me the threadnumber.
threadString = [NSString stringWithFormat:@"%@", thread];
numRange = [threadString rangeOfString:@"num = "];
numLength = [threadString length] - numRange.location - numRange.length;
numRange.location = numRange.location + numRange.length;
numRange.length = numLength - 1;
threadString = [threadString substringWithRange:numRange];
return [threadString intValue];
}
//=====================================================================================================================
// Save a log (a public method)
//=====================================================================================================================
+(void)createLogFromSourceCode:(char*)sourceFile lineNumber:(int)lineNumber withLevel:(int)level withPrivacy:(int)privacy andStringFormat:(const char *)format, ...
{
NSString *logPrefix, *logPostfix;
// Do we need to log this event?
if(level < m_CurrentLogLevel)
// No, the log level is lower than our required level
return;
// Creating prefix and postfix strings
switch(level)
{
case LOG_LEVEL_DEBUG:
logPrefix=[NSString stringWithFormat:@"<%d> [DEBUG]:",[self getThreadNumber:[NSThread currentThread]]];
break;
case LOG_LEVEL_WARN:
logPrefix=[NSString stringWithFormat:@"<%d> [WARN]:",[self getThreadNumber:[NSThread currentThread]]];
break;
case LOG_LEVEL_ERROR:
logPrefix=[NSString stringWithFormat:@"<%d> [ERROR]:",[self getThreadNumber:[NSThread currentThread]]];
break;
case LOG_LEVEL_INFO:
logPrefix=[NSString stringWithFormat:@"<%d> [INFO]:",[self getThreadNumber:[NSThread currentThread]]];
break;
default:
logPrefix=[NSString stringWithFormat:@"<%d> [UNKNOWN]:",[self getThreadNumber:[NSThread currentThread]]];
break;
}
// Create a NSString for the source filename with full path
NSString* srcFile=[NSString stringWithCString:sourceFile];
// Create a scanner
//NSRange srcFileRange=[logPostfix rangeOfCharacterFromSet:[NSCharacterSet characterSetWithCharactersInString:@"/"] options:NSBackwardsSearch];
//logPrefix=[logPostfix substringFromIndex:srcFileRange.location];
// Get path components in an array
NSArray *pathComponents = [srcFile pathComponents];
srcFile=[pathComponents objectAtIndex:[pathComponents count]-1];
// Create a postfix string to show the source and line#
logPostfix=[NSString stringWithFormat:@"(%@#%d):",srcFile, lineNumber];
va_list argp;
va_start(argp, format);
[self saveLogWithLevel:level withPrivacy:privacy andPrefix:[logPrefix UTF8String] andPostfix:[logPostfix UTF8String] andFormat:format andList:argp];
va_end(argp);
}
@end
=============================================== ==============
int main (int argc, const char * argv[]) {
NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
NSThread* thread=NSThread:currentThread; // throws compilation error "Expected expression before thread"
NSRange numRange;
NSUInteger numLength;
NSString* threadString=@"";
// insert code here...
NSLog(@"Hello, World!");
threadString = [NSString stringWithFormat:@"%@", thread];
numRange = [threadString rangeOfString:@"num = "];
numLength = [threadString length] - numRange.location - numRange.length;
numRange.location = numRange.location + numRange.length;
numRange.length = numLength - 1;
threadString = [threadString substringWithRange:numRange];
NSLog(@"%s",threadString);
[pool drain];
return 0;
}