Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/C/Firefox/third_party/rust/tokio/tests/   (Firefox Browser Version 153.0.1©)  Datei vom 27.6.2026 mit Größe 857 B image not shown  

Quelle  signal_info.rs

  Sprache: Rust
 

#![warn(rust_2018_idioms)]
#![cfg(feature = "full")]
#![cfg(any(
    target_os = "dragonfly",
    target_os = "freebsd",
    target_os = "macos",
    target_os = "netbsd",
    target_os = "openbsd",
    target_os = "illumos"
))]
#![cfg(not(miri))] // No `sigaction` on Miri

mod support {
    pub mod signal;
}
use support::signal::send_signal;

use tokio::signal;
use tokio::signal::unix::SignalKind;
use tokio::time::{timeout, Duration};

#[tokio::test]
async fn siginfo() {
    let mut sig = signal::unix::signal(SignalKind::info()).expect("installed signal handler");

    tokio::spawn(async {
        send_signal(libc::SIGINFO);
    });

    // Add a timeout to ensure the test doesn't hang.
    timeout(Duration::from_secs(5), sig.recv())
        .await
        .expect("received SIGINFO signal in time")
        .expect("received SIGINFO signal");
}

Messung V0.5 in Prozent
C=95 H=70 G=83

¤ Dauer der Verarbeitung: 0.3 Sekunden  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

PVS Prover

Isabelle Prover

NIST Cobol Testsuite

Cephes Mathematical Library

Vienna Development Method

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.