Skip to content

Commit

Permalink
Fixed url query string
Browse files Browse the repository at this point in the history
Query string should always start with '\?' instead of '?',
because the question mark has another meaning in shell.
  • Loading branch information
cotox committed Dec 3, 2018
1 parent 6cb5809 commit 4a78f98
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions superbench.sh
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,7 @@ ip_info3() {
}

ip_info4() {
echo $(curl -4 -s https://api.ip.la/en?json) >ip_json.json
echo $(curl -4 -s https://api.ip.la/en\?json) >ip_json.json
country=$(python tools.py ipip country_name)
city=$(python tools.py ipip city)
isp=$(python tools.py geoip isp)
Expand Down Expand Up @@ -605,7 +605,7 @@ sharetest() {
share_link=$(curl -sF 'clbin=<-' https://clbin.com <$log)
;;
'ptpb')
share_link=$(curl -sF c=@- https://ptpb.pw/?u=1 <$log)
share_link=$(curl -sF c=@- https://ptpb.pw/\?u=1 <$log)
;;
esac

Expand All @@ -624,7 +624,7 @@ log_preupload() {

get_ip_whois_org_name() {
#ip=$(curl -s ip.sb)
result=$(curl -s https://rest.db.ripe.net/search.json?query-string=$(curl -s ip.sb))
result=$(curl -s https://rest.db.ripe.net/search.json\?query-string=$(curl -s ip.sb))
#org_name=$(echo $result | jq '.objects.object.[1].attributes.attribute.[1].value' | sed 's/\"//g')
org_name=$(echo $result | jq '.objects.object[1].attributes.attribute[1]' | sed 's/\"//g')
echo $org_name
Expand Down

0 comments on commit 4a78f98

Please sign in to comment.