* src/warc.c (warc_write_cdx_record): Escape URLs

This commit is contained in:
Christof Horschitz 2017-03-22 15:01:04 +01:00 committed by Tim Rühsen
parent e249844143
commit 1d71645c06

View File

@ -32,6 +32,7 @@ as that of the covered work. */
#include "utils.h"
#include "version.h"
#include "dirname.h"
#include "url.h"
#include <stdio.h>
#include <stdlib.h>
@ -1365,6 +1366,8 @@ warc_write_cdx_record (const char *url, const char *timestamp_str,
mime_type = "-";
if (redirect_location == NULL || strlen(redirect_location) == 0)
redirect_location = "-";
else
redirect_location = url_escape(redirect_location);
number_to_string (offset_string, offset);