summaryrefslogtreecommitdiff
path: root/sql/item_func.cc
diff options
context:
space:
mode:
authorpem@mysql.com <>2003-04-16 23:23:23 +0200
committerpem@mysql.com <>2003-04-16 23:23:23 +0200
commit386b0b91b29c41900a916b5445bd8940280274f8 (patch)
treed3271278f467f9e28c64cdd1d735e7f850b5df5e /sql/item_func.cc
parent462430ba558f047c8792ff577b45077aa332856a (diff)
parent03f3b340581b4f438a10f21d4dd08369ab69ff9a (diff)
downloadmariadb-git-386b0b91b29c41900a916b5445bd8940280274f8.tar.gz
Merged 4.1 into 5.0.
Diffstat (limited to 'sql/item_func.cc')
-rw-r--r--sql/item_func.cc14
1 files changed, 13 insertions, 1 deletions
diff --git a/sql/item_func.cc b/sql/item_func.cc
index 05d66f9bfcb..c4afab0f3cb 100644
--- a/sql/item_func.cc
+++ b/sql/item_func.cc
@@ -986,8 +986,20 @@ longlong Item_func_crc32::val_int()
null_value=0;
return (longlong) crc32(0L, (Bytef*)res->ptr(), res->length());
}
-#endif /* HAVE_COMPRESS */
+longlong Item_func_uncompressed_length::val_int()
+{
+ String *res= args[0]->val_str(&value);
+ if (!res)
+ {
+ null_value=1;
+ return 0; /* purecov: inspected */
+ }
+ null_value=0;
+ return uint4korr(res->c_ptr());
+}
+
+#endif /* HAVE_COMPRESS */
longlong Item_func_length::val_int()
{