功能在模拟器中运行,而不是在设备上运行

时间:2010-11-08 11:57:12

标签: iphone simulator

我正在编写一些代码来处理SerwerChanges。我在类ServerChangesArchive中有一个函数:

+(id) httpQueueWithLogin:(NSString*) _login password:(NSString*) _password lastSyncTime:(NSDate*) date;

当我使用Simulator运行此功能时,一切正常,但在设备上我正在

[ServerChangesArchive httpQueueWithLogin:self.login password:self.password lastSyncTime:self.date] 

Incident Identifier: F302A702-69BA-4388-AF9C-CE54426008D4
CrashReporter Key:   2aa75e68ee087cee2b81667dfaa1d8e3b0f5454b
Process:         APPName [420]
Path:            /var/mobile/Applications/E4DAF458-9687-4BDC-A7BC-30357743A33E/Listonic.app/Listonic
Identifier:      APPNAme
Version:         ??? (???)
Code Type:       ARM (Native)
Parent Process:  launchd [1]

Date/Time:       2010-11-08 10:56:54.439 +0100
OS Version:      iPhone OS 3.1.2 (7D11)
Report Version:  104

Exception Type:  EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: KERN_INVALID_ADDRESS at 0x883841bd
Crashed Thread:  5

Thread 0:
0   libSystem.B.dylib              0x3272e4b8 0x3272d000 + 5304
1   libSystem.B.dylib              0x32731094 0x3272d000 + 16532
2   CoreFoundation                 0x32da4002 0x32d4d000 + 356354
3   CoreFoundation                 0x32da3c18 0x32d4d000 + 355352
4   GraphicsServices               0x31bb936c 0x31bb5000 + 17260
5   UIKit                          0x30bf3c28 0x30bf0000 + 15400
6   UIKit                          0x30bf2228 0x30bf0000 + 8744
7   APPName                       0x00002686 main (main.m:13)
8   APPName                       0x0000261c start + 44

Thread 1:
0   libSystem.B.dylib              0x3272e4b8 0x3272d000 + 5304
1   libSystem.B.dylib              0x32731094 0x3272d000 + 16532
2   CoreFoundation                 0x32da4002 0x32d4d000 + 356354
3   CoreFoundation                 0x32da3c18 0x32d4d000 + 355352
4   WebCore                        0x32f486f0 0x32ec4000 + 542448
5   libSystem.B.dylib              0x327587b0 0x3272d000 + 178096

Thread 2:
0   libSystem.B.dylib              0x327be720 0x3272d000 + 595744
1   libSystem.B.dylib              0x32730916 0x3272d000 + 14614
2   Foundation                     0x33f389c8 0x33f29000 + 63944
3   APPName                       0x00006fc8 -[Syncer requestPump] (Syncer.m:114)
4   Foundation                     0x33f7cac6 0x33f29000 + 342726
5   Foundation                     0x33f2ad0e 0x33f29000 + 7438
6   libSystem.B.dylib              0x327587b0 0x3272d000 + 178096

Thread 3:
0   libSystem.B.dylib              0x3272e4b8 0x3272d000 + 5304
1   libSystem.B.dylib              0x32731094 0x3272d000 + 16532
2   CoreFoundation                 0x32da4002 0x32d4d000 + 356354
3   CoreFoundation                 0x32da3c18 0x32d4d000 + 355352
4   Foundation                     0x33f83998 0x33f29000 + 371096
5   Foundation                     0x33f7cac6 0x33f29000 + 342726
6   Foundation                     0x33f2ad0e 0x33f29000 + 7438
7   libSystem.B.dylib              0x327587b0 0x3272d000 + 178096

Thread 4:
0   libSystem.B.dylib              0x327532f0 0x3272d000 + 156400
1   CoreFoundation                 0x32d6d7e2 0x32d4d000 + 133090
2   libSystem.B.dylib              0x327587b0 0x3272d000 + 178096

Thread 5 Crashed:
0   libobjc.A.dylib                0x326704dc 0x32665000 + 46300
1   libobjc.A.dylib                0x32670550 0x32665000 + 46416
2   libobjc.A.dylib                0x32671314 0x32665000 + 49940
3   libobjc.A.dylib                0x3266cf54 0x32665000 + 32596
4   libobjc.A.dylib                0x32668f20 0x32665000 + 16160
5   APPName                       0x0004e9e2 -[ServerChanges requestDidFinishThread:] (ServerChanges.m:352)
6   Foundation                     0x33f7cac6 0x33f29000 + 342726
7   Foundation                     0x33f2ad0e 0x33f29000 + 7438
8   libSystem.B.dylib              0x327587b0 0x3272d000 + 178096

Thread 5 crashed with ARM Thread State:
    r0: 0x3841bd01    r1: 0xffffffff      r2: 0x00000005      r3: 0x00000000
    r4: 0x883841bd    r5: 0x3841bd01      r6: 0x000c39d4      r7: 0x046779cc
    r8: 0x3841bd88    r9: 0x002fc098     r10: 0x00000001     r11: 0x00000000
    ip: 0x38332118    sp: 0x046779b4      lr: 0x32670558      pc: 0x326704dc
  cpsr: 0x20000010

设备甚至不进入此功能体。开始导致问题。

有人能告诉我如何修复它或在哪里搜索explenation吗?

2 个答案:

答案 0 :(得分:2)

崩溃日志显示崩溃是由您的一些代码引起的:

-[ServerChanges requestDidFinishThread:]

或更具体地说,在第352行的文件ServerChanges.m中。

我建议你在这里开始搜索错误。

答案 1 :(得分:0)

这是.xcodeproj问题。删除* .perspectivev3和* .pbxuser文件后,一切都很好:)