summaryrefslogtreecommitdiff
path: root/innobase/include
diff options
context:
space:
mode:
authorunknown <marko@hundin.mysql.fi>2005-02-01 23:55:41 +0200
committerunknown <marko@hundin.mysql.fi>2005-02-01 23:55:41 +0200
commit7d2dcab3a2b67c0dc32846e5ca4e59a9c3cb553b (patch)
tree97559ea7ff57424662133afdfde3ba3f38ed20b4 /innobase/include
parentf7606a335e44841e2cac79cc7256b6eb489c7b82 (diff)
downloadmariadb-git-7d2dcab3a2b67c0dc32846e5ca4e59a9c3cb553b.tar.gz
InnoDB: Fix debug compile error on Tru64 (Bug #8244)
innobase/include/rem0rec.ic: Eliminate int16_t from an assertion, as it is not defined in the same system headers on all platforms. (Bug #8244)
Diffstat (limited to 'innobase/include')
-rw-r--r--innobase/include/rem0rec.ic10
1 files changed, 9 insertions, 1 deletions
diff --git a/innobase/include/rem0rec.ic b/innobase/include/rem0rec.ic
index 366f1c3f77d..2593fb8edeb 100644
--- a/innobase/include/rem0rec.ic
+++ b/innobase/include/rem0rec.ic
@@ -279,7 +279,15 @@ rec_get_next_offs(
/* Note that for 64 KiB pages, field_value can 'wrap around'
and the debug assertion is not valid */
- ut_ad((int16_t)field_value
+ /* In the following assertion, field_value is interpreted
+ as signed 16-bit integer in 2's complement arithmetics.
+ If all platforms defined int16_t in the standard headers,
+ the expression could be written simpler as
+ (int16_t) field_value + ut_align_offset(...) < UNIV_PAGE_SIZE
+ */
+ ut_ad((field_value >= 32768
+ ? field_value - 65536
+ : field_value)
+ ut_align_offset(rec, UNIV_PAGE_SIZE)
< UNIV_PAGE_SIZE);
#endif