mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-25 01:31:08 +00:00
Made initialize test abort if it deadlocks for too long.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@32950 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
e23cad7454
commit
408cec80d5
1 changed files with 3 additions and 0 deletions
|
@ -1,5 +1,6 @@
|
||||||
#import <Foundation/NSThread.h>
|
#import <Foundation/NSThread.h>
|
||||||
#import <Foundation/NSLock.h>
|
#import <Foundation/NSLock.h>
|
||||||
|
#include <unistd.h>
|
||||||
#import "Testing.h"
|
#import "Testing.h"
|
||||||
|
|
||||||
@interface SlowInit0 @end
|
@interface SlowInit0 @end
|
||||||
|
@ -87,6 +88,8 @@ static volatile int finished = 2;
|
||||||
*/
|
*/
|
||||||
int main(void)
|
int main(void)
|
||||||
{
|
{
|
||||||
|
// Die in a signal if this deadlocks.
|
||||||
|
alarm(7);
|
||||||
[NSAutoreleasePool new];
|
[NSAutoreleasePool new];
|
||||||
l = [NSCondition new];
|
l = [NSCondition new];
|
||||||
[l lock];
|
[l lock];
|
||||||
|
|
Loading…
Reference in a new issue