|
From: <sv...@va...> - 2008-05-02 19:12:39
|
Author: bart
Date: 2008-05-02 20:12:43 +0100 (Fri, 02 May 2008)
New Revision: 7992
Log:
Added yet another assertion statement.
Modified:
trunk/exp-drd/drd_clientreq.c
Modified: trunk/exp-drd/drd_clientreq.c
===================================================================
--- trunk/exp-drd/drd_clientreq.c 2008-05-02 18:53:33 UTC (rev 7991)
+++ trunk/exp-drd/drd_clientreq.c 2008-05-02 19:12:43 UTC (rev 7992)
@@ -96,6 +96,11 @@
nframes = VG_(get_StackTrace)(vg_tid, ips, n_ips, sps, 0, 0);
+ /* Paranoia ... */
+ tl_assert(VG_(thread_get_stack_max)(vg_tid)
+ - VG_(thread_get_stack_size)(vg_tid) <= VG_(get_SP)(vg_tid)
+ && VG_(get_SP)(vg_tid) <= VG_(thread_get_stack_max)(vg_tid));
+
husa = (nframes >= 1 ? sps[nframes - 1] : VG_(get_SP)(vg_tid));
tl_assert(VG_(thread_get_stack_max)(vg_tid)
- VG_(thread_get_stack_size)(vg_tid) <= husa
|