File tree 1 file changed +13
-3
lines changed
1 file changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -421,6 +421,7 @@ - (void) start
421
421
ENTER_POOL
422
422
423
423
double prio = [NSThread threadPriority ];
424
+ NSException * caughtException = nil ;
424
425
425
426
AUTORELEASE (RETAIN (self)); // Make sure we exist while running.
426
427
[internal->lock lock ];
@@ -453,12 +454,16 @@ - (void) start
453
454
}
454
455
NS_HANDLER
455
456
{
456
- [internal->lock unlock ];
457
- [localException raise ];
457
+ caughtException = localException;
458
458
}
459
459
NS_ENDHANDLER
460
460
[internal->lock unlock ];
461
461
462
+ if (caughtException != nil )
463
+ {
464
+ [caughtException raise ];
465
+ }
466
+
462
467
NS_DURING
463
468
{
464
469
if (NO == [self isCancelled ])
@@ -470,10 +475,15 @@ - (void) start
470
475
NS_HANDLER
471
476
{
472
477
[NSThread setThreadPriority: prio];
473
- [localException raise ] ;
478
+ caughtException = localException ;
474
479
}
475
480
NS_ENDHANDLER ;
476
481
482
+ if (caughtException != nil )
483
+ {
484
+ [caughtException raise ];
485
+ }
486
+
477
487
[self _finish ];
478
488
LEAVE_POOL
479
489
}
You can’t perform that action at this time.
0 commit comments