|
From: <sv...@va...> - 2009-07-23 17:53:02
|
Author: bart
Date: 2009-07-23 18:52:51 +0100 (Thu, 23 Jul 2009)
New Revision: 10565
Log:
Print an error message if sem_init() is called by a client program on Darwin.
Modified:
trunk/drd/drd_semaphore.c
Modified: trunk/drd/drd_semaphore.c
===================================================================
--- trunk/drd/drd_semaphore.c 2009-07-23 17:51:58 UTC (rev 10564)
+++ trunk/drd/drd_semaphore.c 2009-07-23 17:52:51 UTC (rev 10565)
@@ -200,7 +200,18 @@
}
else
{
+#if defined(VGO_darwin)
+ const ThreadId vg_tid = VG_(get_running_tid)();
+ GenericErrInfo GEI = { DRD_(thread_get_running_tid)() };
+ VG_(maybe_record_error)(vg_tid,
+ GenericErr,
+ VG_(get_IP)(vg_tid),
+ "sem_init() is not yet supported on Darwin",
+ &GEI);
+ return NULL;
+#else
p = drd_semaphore_get_or_allocate(semaphore);
+#endif
}
tl_assert(p);
p->waits_to_skip = value;
|