summary refs log tree commit diff
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2019-09-08 16:25:46 -0400
committerJune McEnroe <june@causal.agency>2019-09-08 16:25:46 -0400
commitd7ac3ac9aa027602fd581d383bc1d40f2d47234f (patch)
tree175ad3f8614504445e0632258d00ee094f33e44d
parentAdd -x flag to title (diff)
downloadsrc-d7ac3ac9aa027602fd581d383bc1d40f2d47234f.tar.gz
src-d7ac3ac9aa027602fd581d383bc1d40f2d47234f.zip
Set title User-Agent
Some things don't like you if you don't send one.
-rw-r--r--bin/title.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/bin/title.c b/bin/title.c
index dacfcf90..816df317 100644
--- a/bin/title.c
+++ b/bin/title.c
@@ -158,6 +158,7 @@ int main(int argc, char *argv[]) {
 	if (!curl) errx(EX_SOFTWARE, "curl_easy_init");
 
 	curl_easy_setopt(curl, CURLOPT_PROTOCOLS, CURLPROTO_HTTP | CURLPROTO_HTTPS);
+	curl_easy_setopt(curl, CURLOPT_USERAGENT, "title/1.0");
 	curl_easy_setopt(curl, CURLOPT_FOLLOWLOCATION, 1L);
 	curl_easy_setopt(curl, CURLOPT_MAXREDIRS, 3L);