mirror of
https://github.com/domcyrus/rustnet.git
synced 2026-01-13 09:49:53 -06:00
fix: Make Windows network functions public
This commit is contained in:
@@ -134,7 +134,7 @@ impl NetworkMonitor {
|
||||
}
|
||||
|
||||
/// Get process information using netstat command
|
||||
fn try_netstat_command(connection: &Connection) -> Option<Process> {
|
||||
pub(super) fn try_netstat_command(connection: &Connection) -> Option<Process> {
|
||||
let output = Command::new("netstat").args(["-ano"]).output().ok()?;
|
||||
|
||||
if output.status.success() {
|
||||
@@ -200,7 +200,7 @@ fn try_netstat_command(connection: &Connection) -> Option<Process> {
|
||||
}
|
||||
|
||||
/// Try Windows API to get process information
|
||||
fn try_windows_api(connection: &Connection) -> Option<Process> {
|
||||
pub(super) fn try_windows_api(connection: &Connection) -> Option<Process> {
|
||||
// This would require using the Windows API (like GetExtendedTcpTable)
|
||||
// For simplicity, we'll just return None as a placeholder
|
||||
// In a real implementation, you'd use the windows crate to make API calls
|
||||
|
||||
Reference in New Issue
Block a user