diff --git a/autospec/license.py b/autospec/license.py index 5874cc9..67924c91 100644 --- a/autospec/license.py +++ b/autospec/license.py @@ -72,6 +72,7 @@ def license_from_copying_hash(copying): c.setopt(c.URL, config.license_fetch) c.setopt(c.WRITEDATA, buffer) c.setopt(c.POSTFIELDS, data) + c.setopt(c.FOLLOWLOCATION, 1) try: c.perform() except Exception as excep: diff --git a/tests/test_license.py b/tests/test_license.py index 5bd9cb0..c37f4cc 100644 --- a/tests/test_license.py +++ b/tests/test_license.py @@ -117,6 +117,7 @@ class TestLicense(unittest.TestCase): URL = None WRITEDATA = None POSTFIELDS = None + FOLLOWLOCATION = 0 def setopt(_, __, ___): pass