Skip to content

Commit

Permalink
Update curl max time to 2
Browse files Browse the repository at this point in the history
  • Loading branch information
jarelllama authored Mar 28, 2024
1 parent fc3d9f3 commit fa6177a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions parked.sh
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ function check_for_unparked {
count=1
# Check for parked message in site's HTML
while read -r domain; do
if ! grep -qiFf "$parked_terms_file" <<< "$(curl -sL --max-time 1 "http://${domain}/" | tr -d '\0')"; then
if ! grep -qiFf "$parked_terms_file" <<< "$(curl -sL --max-time 2 "http://${domain}/" | tr -d '\0')"; then
printf "Unparked: %s\n" "$domain"
printf "%s\n" "$domain" >> "unparked_domains_${1}.tmp"
fi
Expand All @@ -91,7 +91,7 @@ function check_for_parked {
count=1
# Check for parked message in site's HTML
while read -r domain; do
if grep -qiFf "$parked_terms_file" <<< "$(curl -sL --max-time 1 "http://${domain}/" | tr -d '\0')"; then
if grep -qiFf "$parked_terms_file" <<< "$(curl -sL --max-time 2 "http://${domain}/" | tr -d '\0')"; then
printf "Parked: %s\n" "$domain"
printf "%s\n" "$domain" >> "parked_domains_${1}.tmp"
fi
Expand Down
4 changes: 2 additions & 2 deletions test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -294,8 +294,8 @@ function test_dead {
}

function test_parked {
unparked_placeholder=$(head -n 100 "$toplist_file")
parked_placeholder=$(head -n 100 "$parked_domains_file")
unparked_placeholder=$(head -n 50 "$toplist_file")
parked_placeholder=$(head -n 50 "$parked_domains_file")
printf "%s\n" "$unparked_placeholder" > placeholders.txt
printf "%s\n" "$parked_placeholder" >> placeholders.txt
printf "%s\n" "$unparked_placeholder" > "$raw_file"
Expand Down

0 comments on commit fa6177a

Please sign in to comment.