From 02c6fd5dfe142b7cc6f15cb17292504657818498 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Cortier?= <3809077+CBenoit@users.noreply.github.com> Date: Sun, 15 Dec 2024 08:17:04 -0500 Subject: [PATCH] docs(ironrdp): fix server example (#616) The rt-multi-thread feature of tokio is not enabled when compiling the example alone (without feature unification from other crates of the workspace). --- crates/ironrdp/examples/server.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/ironrdp/examples/server.rs b/crates/ironrdp/examples/server.rs index 0ed797a37..6d46f0aa9 100644 --- a/crates/ironrdp/examples/server.rs +++ b/crates/ironrdp/examples/server.rs @@ -16,9 +16,9 @@ use ironrdp::cliprdr::backend::{CliprdrBackend, CliprdrBackendFactory}; use ironrdp::connector::DesktopSize; use ironrdp::rdpsnd::pdu::ClientAudioFormatPdu; use ironrdp::rdpsnd::server::{RdpsndServerHandler, RdpsndServerMessage}; +use ironrdp::server::tokio; use ironrdp::server::tokio::sync::mpsc::UnboundedSender; use ironrdp::server::tokio::time::{self, sleep, Duration}; -use ironrdp::server::tokio::{self}; use ironrdp::server::{ BitmapUpdate, CliprdrServerFactory, Credentials, DisplayUpdate, KeyboardEvent, MouseEvent, PixelFormat, PixelOrder, RdpServer, RdpServerDisplay, RdpServerDisplayUpdates, RdpServerInputHandler, ServerEvent, ServerEventSender, @@ -32,7 +32,7 @@ USAGE: cargo run --example=server -- [--bind-addr ] [--cert ] [--key ] [--user USERNAME] [--pass PASSWORD] [--sec tls|hybrid] "; -#[tokio::main] +#[tokio::main(flavor = "current_thread")] async fn main() -> Result<(), anyhow::Error> { let action = match parse_args() { Ok(action) => action,