Index: libcfa/src/concurrency/locks.cfa
===================================================================
--- libcfa/src/concurrency/locks.cfa	(revision 1dbbef6589e7fa96c6a3e4dfdc0c68971d35cd60)
+++ libcfa/src/concurrency/locks.cfa	(revision 4e83bb73307a616bea9e819e1d7680a4fff893e1)
@@ -237,5 +237,4 @@
 		// This pthread_cond_var member is called from the kernel, and therefore, cannot block, but it can spin.
 		lock( cond->lock __cfaabi_dbg_ctx2 );
-
 		// this check is necessary to avoid a race condition since this timeout handler
 		// 	may still be called after a thread has been removed from the queue but
@@ -347,6 +346,8 @@
 		size_t recursion_count = queue_and_get_recursion(this, &info);
 		alarm_node_wrap(L) node_wrap = { t, 0`s, callback, &this, &info };
+		unlock( lock );
+
+		// registers alarm outside cond lock to avoid deadlock
 		register_self( &node_wrap.alarm_node );
-		unlock( lock );
 
 		// blocks here
@@ -437,4 +438,5 @@
 		if ( ret ) {
 			info_thread(L) & popped = try_pop_front( blocked_threads );
+			popped.signalled = true;
 			on_notify(*popped.lock, popped.t);
 		}
@@ -448,4 +450,5 @@
 		while( ! blocked_threads`isEmpty ) {
 			info_thread(L) & popped = try_pop_front( blocked_threads );
+			popped.signalled = true;
 			on_notify(*popped.lock, popped.t);
 		}
@@ -469,6 +472,8 @@
 		size_t recursion_count = queue_and_get_recursion(this, &info);
 		pthread_alarm_node_wrap(L) node_wrap = { t, 0`s, callback, &this, &info };
+		unlock( lock );
+
+		// registers alarm outside cond lock to avoid deadlock
 		register_self( &node_wrap.alarm_node );
-		unlock( lock );
 
 		// blocks here
@@ -500,12 +505,20 @@
 		return i.signalled;
 
+	Duration getDuration(timespec t) {
+		timespec currTime;
+		clock_gettime(CLOCK_REALTIME, &currTime);
+		Duration waitUntil = { t };
+		Duration currDur = { currTime };
+		if ( currDur >= waitUntil ) return currDur - waitUntil;
+		Duration zero = { 0 };
+		return zero;
+	}
+
 	bool wait( pthread_cond_var(L) & this, L & l, timespec t ) {
-		Duration d = { t };
-		WAIT_TIME( 0, &l , d )
+		PTHREAD_WAIT_TIME( 0, &l , getDuration( t ) )
 	}
 	
 	bool wait( pthread_cond_var(L) & this, L & l, uintptr_t info, timespec t  ) {
-		Duration d = { t };
-		WAIT_TIME( info, &l , d )
+		PTHREAD_WAIT_TIME( info, &l , getDuration( t ) )
 	}
 }
Index: tests/unified_locking/.expect/pthread_locks.txt
===================================================================
--- tests/unified_locking/.expect/pthread_locks.txt	(revision 1dbbef6589e7fa96c6a3e4dfdc0c68971d35cd60)
+++ tests/unified_locking/.expect/pthread_locks.txt	(revision 4e83bb73307a616bea9e819e1d7680a4fff893e1)
@@ -5,2 +5,4 @@
 Start Test 3: lock and condition variable multiple acquire and wait/notify
 Done Test 3
+Start Test 4: lock and condition variable single timed wait/notify
+Done Test 4
Index: tests/unified_locking/pthread_locks.cfa
===================================================================
--- tests/unified_locking/pthread_locks.cfa	(revision 1dbbef6589e7fa96c6a3e4dfdc0c68971d35cd60)
+++ tests/unified_locking/pthread_locks.cfa	(revision 4e83bb73307a616bea9e819e1d7680a4fff893e1)
@@ -3,9 +3,14 @@
 #include <stdlib.hfa>
 #include <thread.hfa>
+#include <time.h>
+#include <stdlib.hfa>
 
-const unsigned int num_times = 50000;
+const unsigned int num_times = 50;
 
 simple_owner_lock l;
 pthread_cond_var( simple_owner_lock ) c;
+
+owner_lock l2;
+condition_variable( owner_lock ) c2;
 
 volatile int counter = 0;
@@ -59,6 +64,23 @@
 }
 
+thread Wait_Time_Signal_1 {};
+
+void main( Wait_Time_Signal_1 & this ) {
+	for (unsigned int i = 0; i < num_times; i++) {
+		lock(l);
+		if(empty(c) || random(10) >= 9 ) {
+			timespec t;
+			clock_gettime(CLOCK_REALTIME, &t);
+			timespec waitTime{0,1};
+			bool woken = wait(c,l, t + waitTime);
+		}else{
+			notify_one(c);
+		}
+		unlock(l);
+	}
+}
+
 int main() {
-	processor p[3];
+	processor p[1];
 	printf("Start Test 1: lock and condition variable single wait/notify\n");
 	{
@@ -78,3 +100,9 @@
 	}
 	printf("Done Test 3\n");
+
+	printf("Start Test 4: lock and condition variable single timed wait/notify\n");
+	{
+		Wait_Time_Signal_1 t1[2];
+	}
+	printf("Done Test 4\n");
 }
