From db24e76397e4466a08e45104a0ac763b1e44b899 Mon Sep 17 00:00:00 2001 From: "mostang.com!davidm" Date: Tue, 20 Apr 2004 23:46:44 +0000 Subject: [PATCH] (mi_init): Use assertion instead of relying on compiler-optimization to verify that unw_cursor_t is big enough to contain a cursor. (Logical change 1.207) --- src/mi/init.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/mi/init.c b/src/mi/init.c index 3d097717..afd97808 100644 --- a/src/mi/init.c +++ b/src/mi/init.c @@ -23,6 +23,7 @@ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +#include #include #include "internal.h" @@ -46,7 +47,6 @@ long unwi_debug_level; HIDDEN void mi_init (void) { - extern void unw_cursor_t_is_too_small (void); #if UNW_DEBUG const char *str = getenv ("UNW_DEBUG_LEVEL"); @@ -60,6 +60,5 @@ mi_init (void) } #endif - if (sizeof (struct cursor) > sizeof (unw_cursor_t)) - unw_cursor_t_is_too_small (); + assert (sizeof (struct cursor) <= sizeof (unw_cursor_t)); }