Hi, Oleksandr!

Mostly ok, one problem below:

On Oct 10, Oleksandr Byelkin wrote:
> revision-id: 2792940391a (mariadb-10.2.31-343-g2792940391a)
> parent(s): 2107e3bb9c0
> author: Oleksandr Byelkin <[email protected]>
> committer: Oleksandr Byelkin <[email protected]>
> timestamp: 2020-07-29 21:54:24 +0200
> message:
> 
> MDEV-23327 Can't uninstall UDF if the implementation library file doesn't 
> exist
> 
> Made cleanup of DROP (udf) FUNCTION procedure and also check of mysql.func 
> (not only loaded udf).
> 
> @@ -606,43 +648,54 @@ int mysql_create_function(THD *thd,udf_func *udf)
>  }
>  
>  
> -int mysql_drop_function(THD *thd,const LEX_STRING *udf_name)
> +enum drop_udf_result mysql_drop_function(THD *thd, const LEX_STRING 
> *udf_name)
>  {
>    TABLE *table;
> -  TABLE_LIST tables;
>    udf_func *udf;
>    DBUG_ENTER("mysql_drop_function");
>  
> +  if (!(table= open_udf_func_table(thd)))
> +    DBUG_RETURN(UDF_DEL_RESULT_ERROR);
> +
> +  // Pre-check without protection
> +  if (!find_udf_everywhere(thd, udf_name->str, udf_name->length, table))

you cannot check the udf_hash without a lock

> +  {
> +    close_mysql_tables(thd);

Regards,
Sergei
VP of MariaDB Server Engineering
and [email protected]

_______________________________________________
Mailing list: https://launchpad.net/~maria-developers
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~maria-developers
More help   : https://help.launchpad.net/ListHelp

Reply via email to