Make sure scalar functions and hooks are Sendable

This commit is contained in:
gwenn
2018-08-15 18:30:18 +02:00
parent ec53f19be1
commit 4770060396
2 changed files with 8 additions and 8 deletions

View File

@@ -230,7 +230,7 @@ impl Connection {
x_func: F,
) -> Result<()>
where
F: FnMut(&Context) -> Result<T>,
F: FnMut(&Context) -> Result<T> + Send,
T: ToSql,
{
self.db
@@ -281,7 +281,7 @@ impl InnerConnection {
x_func: F,
) -> Result<()>
where
F: FnMut(&Context) -> Result<T>,
F: FnMut(&Context) -> Result<T> + Send,
T: ToSql,
{
unsafe extern "C" fn call_boxed_closure<F, T>(