* It helps a lot to find thread problems when the multi locker assert macros actually doing something useful. Took me forever to finally realise that and to find a threading bug.

* Remove a superfluously assert which sends the app server into the debugger. More fixes following.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42472 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Clemens Zeidler
2011-07-24 10:50:33 +00:00
parent 781a7c361d
commit d5314ec095
2 changed files with 4 additions and 4 deletions
+4 -3
View File
@@ -25,13 +25,14 @@
#define MULTI_LOCKER_TIMING 0
#if DEBUG
# include <assert.h>
# define MULTI_LOCKER_DEBUG DEBUG
#endif
#if MULTI_LOCKER_DEBUG
# define ASSERT_MULTI_LOCKED(x) ((x).IsWriteLocked() || (x).IsReadLocked())
# define ASSERT_MULTI_READ_LOCKED(x) ((x).IsReadLocked())
# define ASSERT_MULTI_WRITE_LOCKED(x) ((x).IsWriteLocked())
# define ASSERT_MULTI_LOCKED(x) assert((x).IsWriteLocked() || (x).IsReadLocked())
# define ASSERT_MULTI_READ_LOCKED(x) assert((x).IsReadLocked())
# define ASSERT_MULTI_WRITE_LOCKED(x) assert((x).IsWriteLocked())
#else
# define MULTI_LOCKER_DEBUG 0
# define ASSERT_MULTI_LOCKED(x) ;
-1
View File
@@ -82,7 +82,6 @@ Workspace::Workspace(Desktop& desktop, int32 index)
fDesktop(desktop),
fCurrentWorkspace(index == desktop.CurrentWorkspace())
{
ASSERT_MULTI_LOCKED(desktop.WindowLocker());
RewindWindows();
}