From: Behdad Esfahbod Date: Thu, 28 Apr 2011 19:54:16 +0000 (-0400) Subject: Desable possibly lethal test on 64-bit machines X-Git-Tag: submit/master/20120920.151126~7^2~301 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1d39d6e42b3d7628512d675a84a831a0f58624eb;p=framework%2Fuifw%2Fharfbuzz.git Desable possibly lethal test on 64-bit machines --- diff --git a/test/test-buffer.c b/test/test-buffer.c index 61a1b48..7da4c92 100644 --- a/test/test-buffer.c +++ b/test/test-buffer.c @@ -304,9 +304,12 @@ test_buffer_allocation (fixture_t *fixture, gconstpointer user_data) g_assert (hb_buffer_allocation_successful (fixture->b)); /* technically, this one can actually pass on 64bit machines, but - * I'm doubtful that any malloc allows 4GB allocations at a time. */ - g_assert (!hb_buffer_pre_allocate (fixture->b, ((unsigned int) -1) / 20 - 1)); - g_assert (!hb_buffer_allocation_successful (fixture->b)); + * I'm doubtful that any malloc allows 4GB allocations at a time. + * But let's only enable it on a 32-bit machine. */ + if (sizeof (long) == 4) { + g_assert (!hb_buffer_pre_allocate (fixture->b, ((unsigned int) -1) / 20 - 1)); + g_assert (!hb_buffer_allocation_successful (fixture->b)); + } hb_buffer_reset (fixture->b); g_assert (hb_buffer_allocation_successful (fixture->b));