From bd894f98cc5e899b2ddaf95313f687cf1aea6c44 Mon Sep 17 00:00:00 2001 From: Joshua Harlow Date: Thu, 23 Jan 2014 17:36:18 -0800 Subject: [PATCH] Use the right exception --- cloudinit/url_helper.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cloudinit/url_helper.py b/cloudinit/url_helper.py index 42edf9cf..227983f3 100644 --- a/cloudinit/url_helper.py +++ b/cloudinit/url_helper.py @@ -195,7 +195,7 @@ def readurl(url, data=None, timeout=None, retries=0, sec_between=1, # ssl exceptions are not going to get fixed by waiting a # few seconds break - if exception_cb and not exception_cb(filtered_req_args, e): + if exception_cb and not exception_cb(filtered_req_args, excps[-1]): break if i + 1 < manual_tries and sec_between > 0: LOG.debug("Please wait %s seconds while we wait to try again",