File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -790,8 +790,9 @@ pub extern "C" fn mcp_list_tools_init() -> usize {
790790 let runtime_handle = client. runtime . handle ( ) . clone ( ) ;
791791
792792 // Use spawn_blocking which handles FFI context better on Windows
793+ let runtime_handle_clone = runtime_handle. clone ( ) ;
793794 runtime_handle. spawn_blocking ( move || {
794- runtime_handle . block_on ( async move {
795+ runtime_handle_clone . block_on ( async move {
795796 let service_guard = service_arc. lock ( ) . await ;
796797 if let Some ( service) = service_guard. as_ref ( ) {
797798 match service. list_tools ( None ) . await {
@@ -877,8 +878,9 @@ pub extern "C" fn mcp_call_tool_init(tool_name: *const c_char, arguments: *const
877878 let runtime_handle = client. runtime . handle ( ) . clone ( ) ;
878879
879880 // Use spawn_blocking which handles FFI context better on Windows
881+ let runtime_handle_clone = runtime_handle. clone ( ) ;
880882 runtime_handle. spawn_blocking ( move || {
881- runtime_handle . block_on ( async move {
883+ runtime_handle_clone . block_on ( async move {
882884 let service_guard = service_arc. lock ( ) . await ;
883885 if let Some ( service) = service_guard. as_ref ( ) {
884886 // Parse arguments
You can’t perform that action at this time.
0 commit comments