Warning: session_start(): open(/var/lib/php/sessions/sess_50et41869i8em5uamattu2kvvd, O_RDWR) failed: No space left on device (28) in /var/www/tb-usercake/models/config.php on line 51
Warning: session_start(): Failed to read session data: files (path: /var/lib/php/sessions) in /var/www/tb-usercake/models/config.php on line 51
!7
static Lock a = fairLock();
static Lock b = fairLock();
static int timeout = 10000;
p-tt {
centerHigherConsole();
startDeadlockDetector();
print("Initiating deadlock with timeout " + timeout + " ms... :-)\n");
thread "A" {
lockOrFail(a, timeout);
try {
print("Thread A has lock A.");
sleep1Second();
print("Thread A getting lock B.");
lockOrFail(b, timeout);
try {
print("Thread A sleeping.");
main.sleep();
} finally {
b.unlock();
}
} finally {
a.unlock();
}
}
thread "B" {
lockOrFail(b, timeout);
try {
print("Thread B has lock B.");
sleep1Second();
print("Thread B getting lock A.");
lockOrFail(a, timeout);
try {
print("Thread B sleeping.");
main.sleep();
} finally {
a.unlock();
}
} finally {
b.unlock();
}
}
sleepQuietly();
}