summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/process_url.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/process_url.c b/src/process_url.c
index 30b7f71..7d04f37 100644
--- a/src/process_url.c
+++ b/src/process_url.c
@@ -175,8 +175,8 @@ static int parse_url(const char *URL, const char *outdir, char *fn) {
append_log("Got site: %s\n", domain);
thrd_t t;
options.site = site_map.pairs[i].site;
- options.URL = malloc(strlen(domain) + strlen(path) + 10);
- sprintf(options.URL, "https://%s%s", domain, path);
+ options.URL = malloc(strlen(URL) + 1);
+ strcpy(options.URL, URL);
options.path = malloc(strlen(path) + 1);
strcpy(options.path, path);
if (query) {