mirror of
https://github.com/edu4rdshl/rusolver.git
synced 2026-07-17 23:24:55 +00:00
(fix): only print data if quiet_mode is not set. Also do not print wildcards
This commit is contained in:
parent
3bb0ac4b35
commit
28b29ca515
4 changed files with 6 additions and 4 deletions
2
Cargo.lock
generated
2
Cargo.lock
generated
|
|
@ -926,7 +926,7 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "rusolver"
|
||||
version = "0.10.0"
|
||||
version = "0.10.1"
|
||||
dependencies = [
|
||||
"clap",
|
||||
"futures",
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
[package]
|
||||
name = "rusolver"
|
||||
version = "0.10.0"
|
||||
version = "0.10.1"
|
||||
authors = ["Eduard Tolosa <edu4rdshl@protonmail.com>"]
|
||||
edition = "2021"
|
||||
description = "Fast DNS resolver written in Rust."
|
||||
|
|
|
|||
|
|
@ -85,7 +85,9 @@ pub async fn return_hosts_data(options: &LibOptions) -> HashMap<String, DomainDa
|
|||
.iter()
|
||||
.all(|ip| wildcard_ips.contains(ip));
|
||||
|
||||
print_domain_data(&host, &domain_data, &options);
|
||||
if !options.quiet_flag {
|
||||
print_domain_data(&host, &domain_data, options);
|
||||
}
|
||||
|
||||
(host, domain_data)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -89,7 +89,7 @@ pub async fn detect_wildcards(
|
|||
}
|
||||
|
||||
pub fn print_domain_data(host: &str, domain_data: &DomainData, options: &LibOptions) {
|
||||
if options.show_ip_address {
|
||||
if options.show_ip_address && !domain_data.is_wildcard {
|
||||
println!("{}: {:?}", host, domain_data.ipv4_addresses);
|
||||
} else {
|
||||
println!("{}", host);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue