qychen1982 / crashpad

Automatically exported from code.google.com/p/crashpad
0 stars 0 forks source link

HTTPTransport tests fail (uncaught NSException) on Mac OS X 10.6, 10.7, and 10.8 #15

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
mark@ten-eight-vm bash$ out/Debug/crashpad_util_test 
--gtest_filter=HTTPTransport\*
Running main() from gmock_main.cc
Note: Google Test filter = HTTPTransport*
[==========] Running 3 tests from 1 test case.
[----------] Global test environment set-up.
[----------] 3 tests from HTTPTransport
[ RUN      ] HTTPTransport.ValidFormData
2015-03-11 00:15:58.012 crashpad_util_test[536:1803] 
-[CrashpadHTTPBodyStreamTransport _scheduleInCFRunLoop:forMode:]: unrecognized 
selector sent to instance 0x7fe82ac210b0
2015-03-11 00:15:58.014 crashpad_util_test[536:1803] *** Terminating app due to 
uncaught exception 'NSInvalidArgumentException', reason: 
'-[CrashpadHTTPBodyStreamTransport _scheduleInCFRunLoop:forMode:]: unrecognized 
selector sent to instance 0x7fe82ac210b0'
*** First throw call stack:
(
    0   CoreFoundation                      0x00007fff8e435b06 __exceptionPreprocess + 198
    1   libobjc.A.dylib                     0x00007fff8552a3f0 objc_exception_throw + 43
    2   CoreFoundation                      0x00007fff8e4cc40a -[NSObject(NSObject) doesNotRecognizeSelector:] + 186
    3   CoreFoundation                      0x00007fff8e42402e ___forwarding___ + 414
    4   CoreFoundation                      0x00007fff8e423e18 _CF_forwarding_prep_0 + 232
    5   CFNetwork                           0x00007fff87f96d05 _ZN30CoreReadStreamFromCFReadStream28_streamImpl_UpdateSchedulingEPK17CoreSchedulingSetS2_ + 141
    6   CFNetwork                           0x00007fff87f70a92 _ZN14CoreStreamBase33_streamInterface_UpdateSchedulingEPK17CoreSchedulingSet + 486
    7   CFNetwork                           0x00007fff87f96c51 _ZL21_streamScheduleUpdateP14CoreStreamBasehP11__CFRunLoopPK10__CFString + 60
    8   CFNetwork                           0x00007fff87f70d13 _ZN24CoreStreamImplementation28_streamImpl_UpdateSchedulingEPK17CoreSchedulingSetS2_ + 141
    9   CFNetwork                           0x00007fff87f70a92 _ZN14CoreStreamBase33_streamInterface_UpdateSchedulingEPK17CoreSchedulingSet + 486
    10  CFNetwork                           0x00007fff87f96138 _ZN12HTTPProtocol10openStreamEv + 248
    11  CFNetwork                           0x00007fff87f955f4 _ZN12HTTPProtocol26useNetConnectionForRequestEP13NetConnectionP15__CFHTTPMessagehh + 910
    12  CFNetwork                           0x00007fff87f9501e _ZN24HTTPConnectionCacheEntry28dispatchConnectionToProtocolEP13NetConnectionP12HTTPProtocolP18HTTPRequestMessageh + 244
    13  CFNetwork                           0x00007fff87f94e5d _ZN24HTTPConnectionCacheEntry34notifyNextProtocolOfOpenConnectionEP13NetConnectionh + 411
    14  CFNetwork                           0x00007fff87f92843 _ZN24HTTPConnectionCacheEntry25enqueueRequestForProtocolEP12HTTPProtocolP15__CFHTTPMessage + 645
    15  CFNetwork                           0x00007fff87f921b0 _ZN19HTTPConnectionCache34_onqueue_enqueueRequestForProtocolEP12HTTPProtocolP15__CFHTTPMessage + 178
    16  CFNetwork                           0x00007fff87f920d5 __enqueueRequestForProtocol_block_invoke_0 + 26
    17  CFNetwork                           0x00007fff8802beba __block_global_1 + 28
    18  CoreFoundation                      0x00007fff8e3d3154 CFArrayApplyFunction + 68
    19  CFNetwork                           0x00007fff87f8c014 _ZN19RunloopBlockContext7performEv + 124
    20  CFNetwork                           0x00007fff87f8beeb _ZN17MultiplexerSource7performEv + 221
    21  CoreFoundation                      0x00007fff8e3b4b31 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
    22  CoreFoundation                      0x00007fff8e3b4455 __CFRunLoopDoSources0 + 245
    23  CoreFoundation                      0x00007fff8e3d77f5 __CFRunLoopRun + 789
    24  CoreFoundation                      0x00007fff8e3d70e2 CFRunLoopRunSpecific + 290
    25  Foundation                          0x00007fff9048e526 +[NSURLConnection(Loader) _resourceLoadLoop:] + 356
    26  Foundation                          0x00007fff904ec532 __NSThread__main__ + 1345
    27  libsystem_c.dylib                   0x00007fff8a2f7772 _pthread_start + 327
    28  libsystem_c.dylib                   0x00007fff8a2e41a1 thread_start + 13
)
libc++abi.dylib: terminate called throwing an exception
Abort trap: 6
mark@ten-eight-vm bash$

The corresponding ReportCrash log is also attached. The main thread is, not 
surprisingly, in HTTPTransportMac::ExecuteSynchronously()’s call to 
+[NSURLConnection sendSynchronousRequest:returningResponse:error:].

This affects 10.6, 10.7, and 10.8.

Original issue reported on code.google.com by mark@chromium.org on 11 Mar 2015 at 4:25

Attachments:

GoogleCodeExporter commented 9 years ago

Original comment by rsesek@chromium.org on 11 Mar 2015 at 7:27

GoogleCodeExporter commented 9 years ago
https://codereview.chromium.org/993413003/ : 
https://chromium.googlesource.com/crashpad/crashpad/+/f0ee5f0efee651ab82aa854761
f107193b3db5de

Original comment by rsesek@chromium.org on 11 Mar 2015 at 9:00