summaryrefslogtreecommitdiff
path: root/sql/udf_example.c
diff options
context:
space:
mode:
authormsvensson@pilot.(none) <>2007-08-09 10:21:28 +0200
committermsvensson@pilot.(none) <>2007-08-09 10:21:28 +0200
commit9d06483f72c0c46006db0a2b75b6813100679ae8 (patch)
tree2eee5289850a309ca91b90a48de766e3afc8f452 /sql/udf_example.c
parenta933f28a937dd8e6b547a68c94b1baedd3a5ff2d (diff)
downloadmariadb-git-9d06483f72c0c46006db0a2b75b6813100679ae8.tar.gz
Bug#29804 UDF parameters don't contain correct string length
- Fix warnings - Export 'check_const_len' from udf_example.dll
Diffstat (limited to 'sql/udf_example.c')
-rw-r--r--sql/udf_example.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sql/udf_example.c b/sql/udf_example.c
index 5165a577555..6c07a929b04 100644
--- a/sql/udf_example.c
+++ b/sql/udf_example.c
@@ -1115,15 +1115,15 @@ my_bool check_const_len_init(UDF_INIT *initid, UDF_ARGS *args, char *message)
}
if (args->args[0] == 0)
{
- initid->ptr= "Not constant";
+ initid->ptr= (char*)"Not constant";
}
else if(strlen(args->args[0]) == args->lengths[0])
{
- initid->ptr= "Correct length";
+ initid->ptr= (char*)"Correct length";
}
else
{
- initid->ptr= "Wrong length";
+ initid->ptr= (char*)"Wrong length";
}
initid->max_length = 100;
return 0;