<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html lang="en">
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
<title>
GitLab
</title>



<style>img {
max-width: 100%; height: auto;
}
</style>
</head>
<body>
<div class="content">
<h3>
Ian Bruene pushed to branch master
at <a href="https://gitlab.com/NTPsec/ntpsec">NTPsec / ntpsec</a>
</h3>
<h4>
Commits:
</h4>
<ul>
<li>
<strong><a href="https://gitlab.com/NTPsec/ntpsec/commit/9795f701fc82fb78698a962dddcbd025c933fcca">9795f701</a></strong>
<div>
<span>by Ian Bruene</span>
<i>at 2018-01-01T13:17:35-06:00</i>
</div>
<pre class="commit-message" style="white-space: pre-wrap; margin: 0;">Moved DNS caching to timed_canonicalize_dns() function
</pre>
</li>
</ul>
<h4>2 changed files:</h4>
<ul>
<li class="file-stats">
<a href="#a61fb9541c7ffe95e3b809ea55001114580d13e4">
pylib/util.py
</a>
</li>
<li class="file-stats">
<a href="#212369a2f3b2454ae6823fc589f4a77ae148f6cd">
tests/pylib/test_util.py
</a>
</li>
</ul>
<h4>Changes:</h4>
<li id="a61fb9541c7ffe95e3b809ea55001114580d13e4">
<a href="https://gitlab.com/NTPsec/ntpsec/commit/9795f701fc82fb78698a962dddcbd025c933fcca#a61fb9541c7ffe95e3b809ea55001114580d13e4"><strong>pylib/util.py</strong></a>
<hr>
<table class="code white" style="font-family: monospace; font-size: 12px;" bgcolor="#fff" width="100%" cellpadding="0" cellspacing="0">
<tr class="line_holder match" id="" style="line-height: 1.6;">
<td class="diff-line-num unfold js-unfold old_line" data-linenumber="558" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="diff-line-num unfold js-unfold new_line" data-linenumber="558" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="line_content match " style="padding-left: 0.5em; padding-right: 0.5em; color: rgba(0,0,0,0.3);" bgcolor="#fafafa">@@ -558,6 +558,9 @@ import subprocess</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="558" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
558
</td>
<td class="diff-line-num new_line" data-linenumber="558" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
558
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC558" class="line" lang="python"></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="559" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
559
</td>
<td class="diff-line-num new_line" data-linenumber="559" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
559
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC559" class="line" lang="python"></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="560" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
560
</td>
<td class="diff-line-num new_line" data-linenumber="560" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
560
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC560" class="line" lang="python"><span class="k" style="font-weight: 600;">def</span> <span class="nf" style="color: #900; font-weight: 600;">timed_canonicalize_dns</span><span class="p">(</span><span class="n" style="color: #333;">inhost</span><span class="p">,</span> <span class="n" style="color: #333;">family</span><span class="o" style="font-weight: 600;">=</span><span class="n" style="color: #333;">socket</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">AF_UNSPEC</span><span class="p">,</span> <span class="n" style="color: #333;">ttl</span><span class="o" style="font-weight: 600;">=</span><span class="mf" style="color: #099;">1.0</span><span class="p">):</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6;">
<td class="diff-line-num new old_line" data-linenumber="561" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="561" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
561
</td>
<td class="line_content new noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#ecfdf0">
<pre style="margin: 0;">+<span id="LC561" class="line" lang="python">    <span class="n" style="color: #333;">resname</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">canonicalization_cache</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">get</span><span class="p">(</span><span class="n" style="color: #333;">inhost</span><span class="p">)</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6;">
<td class="diff-line-num new old_line" data-linenumber="561" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="562" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
562
</td>
<td class="line_content new noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#ecfdf0">
<pre style="margin: 0;">+<span id="LC562" class="line" lang="python">    <span class="k" style="font-weight: 600;">if</span> <span class="n" style="color: #333;">resname</span> <span class="ow" style="font-weight: 600;">is</span> <span class="ow" style="font-weight: 600;">not</span> <span class="bp" style="color: #999;">None</span><span class="p">:</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6;">
<td class="diff-line-num new old_line" data-linenumber="561" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="563" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
563
</td>
<td class="line_content new noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#ecfdf0">
<pre style="margin: 0;">+<span id="LC563" class="line" lang="python">        <span class="k" style="font-weight: 600;">return</span> <span class="n" style="color: #333;">resname</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="561" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
561
</td>
<td class="diff-line-num new_line" data-linenumber="564" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
564
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC564" class="line" lang="python">    <span class="n" style="color: #333;">cmd</span> <span class="o" style="font-weight: 600;">=</span> <span class="s" style="color: #d14;">"import ntp.util; print(ntp.util.canonicalize_dns('</span><span class="si" style="color: #d14;">%</span><span class="s" style="color: #d14;">s', </span><span class="si" style="color: #d14;">%</span><span class="s" style="color: #d14;">s))"</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="562" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
562
</td>
<td class="diff-line-num new_line" data-linenumber="565" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
565
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC565" class="line" lang="python">    <span class="n" style="color: #333;">cmd</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">cmd</span> <span class="o" style="font-weight: 600;">%</span> <span class="p">(</span><span class="nb" style="color: #0086b3;">str</span><span class="p">(</span><span class="n" style="color: #333;">inhost</span><span class="p">),</span> <span class="nb" style="color: #0086b3;">str</span><span class="p">(</span><span class="n" style="color: #333;">family</span><span class="p">))</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="563" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
563
</td>
<td class="diff-line-num new_line" data-linenumber="566" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
566
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC566" class="line" lang="python">    <span class="n" style="color: #333;">p</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">subprocess</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">Popen</span><span class="p">([</span><span class="s" style="color: #d14;">"python"</span><span class="p">,</span> <span class="s" style="color: #d14;">"-c"</span><span class="p">,</span> <span class="n" style="color: #333;">cmd</span><span class="p">],</span></span>
</pre>
</td>
</tr>
<tr class="line_holder match" id="" style="line-height: 1.6;">
<td class="diff-line-num unfold js-unfold old_line" data-linenumber="571" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="diff-line-num unfold js-unfold new_line" data-linenumber="574" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="line_content match " style="padding-left: 0.5em; padding-right: 0.5em; color: rgba(0,0,0,0.3);" bgcolor="#fafafa">@@ -571,13 +574,12 @@ def timed_canonicalize_dns(inhost, family=socket.AF_UNSPEC, ttl=1.0):</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="571" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
571
</td>
<td class="diff-line-num new_line" data-linenumber="574" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
574
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC574" class="line" lang="python">            <span class="n" style="color: #333;">p</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">terminate</span><span class="p">()</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="572" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
572
</td>
<td class="diff-line-num new_line" data-linenumber="575" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
575
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC575" class="line" lang="python">            <span class="k" style="font-weight: 600;">return</span> <span class="n" style="color: #333;">inhost</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="573" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
573
</td>
<td class="diff-line-num new_line" data-linenumber="576" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
576
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC576" class="line" lang="python">        <span class="n" style="color: #333;">time</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">sleep</span><span class="p">(</span><span class="o" style="font-weight: 600;">.</span><span class="mo" style="color: #099;">01</span><span class="p">)</span>  <span class="c" style="color: #998; font-style: italic;"># don't waste cycles with spinning</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="574" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
574
</td>
<td class="diff-line-num new_line old" data-linenumber="577" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC574" class="line" lang="python">    <span class="k" style="font-weight: 600;">return</span> <span class="n" style="color: #333;">p</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">communicate</span><span class="p">()[</span><span class="mi" style="color: #099;">0</span><span class="p">]</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">strip</span><span class="p">(</span><span class="s" style="color: #d14;">"</span><span class="se" style="color: #d14;">\n</span><span class="s" style="color: #d14;">"</span><span class="p">)</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6;">
<td class="diff-line-num new old_line" data-linenumber="575" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="577" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
577
</td>
<td class="line_content new noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#ecfdf0">
<pre style="margin: 0;">+<span id="LC577" class="line" lang="python">    <span class="n" style="color: #333;">result</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">p</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">communicate</span><span class="p">()[</span><span class="mi" style="color: #099;">0</span><span class="p">]</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">strip</span><span class="p">(</span><span class="s" style="color: #d14;">"</span><span class="se" style="color: #d14;">\n</span><span class="s" style="color: #d14;">"</span><span class="p">)</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6;">
<td class="diff-line-num new old_line" data-linenumber="575" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="578" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
578
</td>
<td class="line_content new noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#ecfdf0">
<pre style="margin: 0;">+<span id="LC578" class="line" lang="python">    <span class="n" style="color: #333;">canonicalization_cache</span><span class="o" style="font-weight: 600;">.</span><span class="nb" style="color: #0086b3;">set</span><span class="p">(</span><span class="n" style="color: #333;">inhost</span><span class="p">,</span> <span class="n" style="color: #333;">result</span><span class="p">)</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6;">
<td class="diff-line-num new old_line" data-linenumber="575" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="579" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
579
</td>
<td class="line_content new noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#ecfdf0">
<pre style="margin: 0;">+<span id="LC579" class="line" lang="python">    <span class="k" style="font-weight: 600;">return</span> <span class="n" style="color: #333;">result</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="575" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
575
</td>
<td class="diff-line-num new_line" data-linenumber="580" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
580
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC580" class="line" lang="python"></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="576" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
576
</td>
<td class="diff-line-num new_line" data-linenumber="581" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
581
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC581" class="line" lang="python"><span class="k" style="font-weight: 600;">def</span> <span class="nf" style="color: #900; font-weight: 600;">canonicalize_dns</span><span class="p">(</span><span class="n" style="color: #333;">inhost</span><span class="p">,</span> <span class="n" style="color: #333;">family</span><span class="o" style="font-weight: 600;">=</span><span class="n" style="color: #333;">socket</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">AF_UNSPEC</span><span class="p">):</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="577" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
577
</td>
<td class="diff-line-num new_line" data-linenumber="582" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
582
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC582" class="line" lang="python">    <span class="s" style="color: #d14;">"Canonicalize a hostname or numeric IP address."</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="578" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
578
</td>
<td class="diff-line-num new_line old" data-linenumber="583" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC578" class="line" lang="python">    <span class="n" style="color: #333;">resname</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">canonicalization_cache</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">get</span><span class="p">(</span><span class="n" style="color: #333;">inhost</span><span class="p">)</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="579" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
579
</td>
<td class="diff-line-num new_line old" data-linenumber="583" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC579" class="line" lang="python">    <span class="k" style="font-weight: 600;">if</span> <span class="n" style="color: #333;">resname</span> <span class="ow" style="font-weight: 600;">is</span> <span class="ow" style="font-weight: 600;">not</span> <span class="bp" style="color: #999;">None</span><span class="p">:</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="580" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
580
</td>
<td class="diff-line-num new_line old" data-linenumber="583" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC580" class="line" lang="python">        <span class="k" style="font-weight: 600;">return</span> <span class="n" style="color: #333;">resname</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="581" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
581
</td>
<td class="diff-line-num new_line" data-linenumber="583" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
583
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC583" class="line" lang="python">    <span class="c" style="color: #998; font-style: italic;"># Catch garbaged hostnames in corrupted Mode 6 responses</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="582" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
582
</td>
<td class="diff-line-num new_line" data-linenumber="584" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
584
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC584" class="line" lang="python">    <span class="n" style="color: #333;">m</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">re</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">match</span><span class="p">(</span><span class="s" style="color: #d14;">"([:.[</span><span class="err" style="color: #a61717; background-color: #e3d2d2;">\</span><span class="s" style="color: #d14;">]]|</span><span class="err" style="color: #a61717; background-color: #e3d2d2;">\</span><span class="s" style="color: #d14;">w)*"</span><span class="p">,</span> <span class="n" style="color: #333;">inhost</span><span class="p">)</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="583" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
583
</td>
<td class="diff-line-num new_line" data-linenumber="585" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
585
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC585" class="line" lang="python">    <span class="k" style="font-weight: 600;">if</span> <span class="ow" style="font-weight: 600;">not</span> <span class="n" style="color: #333;">m</span><span class="p">:</span></span>
</pre>
</td>
</tr>
<tr class="line_holder match" id="" style="line-height: 1.6;">
<td class="diff-line-num unfold js-unfold old_line" data-linenumber="597" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="diff-line-num unfold js-unfold new_line" data-linenumber="599" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="line_content match " style="padding-left: 0.5em; padding-right: 0.5em; color: rgba(0,0,0,0.3);" bgcolor="#fafafa">@@ -597,7 +599,6 @@ def canonicalize_dns(inhost, family=socket.AF_UNSPEC):</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="597" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
597
</td>
<td class="diff-line-num new_line" data-linenumber="599" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
599
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC599" class="line" lang="python">        <span class="c" style="color: #998; font-style: italic;"># Fall back to the hostname.</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="598" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
598
</td>
<td class="diff-line-num new_line" data-linenumber="600" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
600
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC600" class="line" lang="python">        <span class="n" style="color: #333;">canonicalized</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">canonname</span> <span class="ow" style="font-weight: 600;">or</span> <span class="n" style="color: #333;">hostname</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="599" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
599
</td>
<td class="diff-line-num new_line" data-linenumber="601" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
601
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC601" class="line" lang="python">        <span class="n" style="color: #333;">result</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">canonicalized</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">lower</span><span class="p">()</span> <span class="o" style="font-weight: 600;">+</span> <span class="n" style="color: #333;">portsuffix</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="600" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
600
</td>
<td class="diff-line-num new_line old" data-linenumber="602" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC600" class="line" lang="python">    <span class="n" style="color: #333;">canonicalization_cache</span><span class="o" style="font-weight: 600;">.</span><span class="nb" style="color: #0086b3;">set</span><span class="p">(</span><span class="n" style="color: #333;">inhost</span><span class="p">,</span> <span class="n" style="color: #333;">result</span><span class="p">)</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="601" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
601
</td>
<td class="diff-line-num new_line" data-linenumber="602" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
602
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC602" class="line" lang="python">    <span class="k" style="font-weight: 600;">return</span> <span class="n" style="color: #333;">result</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="602" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
602
</td>
<td class="diff-line-num new_line" data-linenumber="603" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
603
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC603" class="line" lang="python"></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="603" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
603
</td>
<td class="diff-line-num new_line" data-linenumber="604" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
604
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC604" class="line" lang="python"></span>
</pre>
</td>
</tr>

</table>
<br>
</li>
<li id="212369a2f3b2454ae6823fc589f4a77ae148f6cd">
<a href="https://gitlab.com/NTPsec/ntpsec/commit/9795f701fc82fb78698a962dddcbd025c933fcca#212369a2f3b2454ae6823fc589f4a77ae148f6cd"><strong>tests/pylib/test_util.py</strong></a>
<hr>
<table class="code white" style="font-family: monospace; font-size: 12px;" bgcolor="#fff" width="100%" cellpadding="0" cellspacing="0">
<tr class="line_holder match" id="" style="line-height: 1.6;">
<td class="diff-line-num unfold js-unfold old_line" data-linenumber="510" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="diff-line-num unfold js-unfold new_line" data-linenumber="510" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="line_content match " style="padding-left: 0.5em; padding-right: 0.5em; color: rgba(0,0,0,0.3);" bgcolor="#fafafa">@@ -510,17 +510,9 @@ class TestPylibUtilMethods(unittest.TestCase):</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="510" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
510
</td>
<td class="diff-line-num new_line" data-linenumber="510" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
510
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC510" class="line" lang="python">        <span class="n" style="color: #333;">f</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">ntp</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">util</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">canonicalize_dns</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="511" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
511
</td>
<td class="diff-line-num new_line" data-linenumber="511" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
511
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC511" class="line" lang="python"></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="512" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
512
</td>
<td class="diff-line-num new_line" data-linenumber="512" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
512
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC512" class="line" lang="python">        <span class="n" style="color: #333;">fakesockmod</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">jigs</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">SocketModuleJig</span><span class="p">()</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="513" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
513
</td>
<td class="diff-line-num new_line old" data-linenumber="513" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC513" class="line" lang="python">        <span class="n" style="color: #333;">mycache</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">ntp</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">util</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">Cache</span><span class="p">()</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="514" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
514
</td>
<td class="diff-line-num new_line old" data-linenumber="513" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC514" class="line" lang="python">        <span class="n" style="color: #333;">mycache</span><span class="o" style="font-weight: 600;">.</span><span class="nb" style="color: #0086b3;">set</span><span class="p">(</span><span class="s" style="color: #d14;">"foo"</span><span class="p">,</span> <span class="s" style="color: #d14;">"bar"</span><span class="p">)</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="515" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
515
</td>
<td class="diff-line-num new_line" data-linenumber="513" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
513
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC513" class="line" lang="python">        <span class="k" style="font-weight: 600;">try</span><span class="p">:</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="516" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
516
</td>
<td class="diff-line-num new_line old" data-linenumber="514" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC516" class="line" lang="python">            <span class="n" style="color: #333;">cachetemp</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">ntp</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">util</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">canonicalization_cache</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="517" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
517
</td>
<td class="diff-line-num new_line old" data-linenumber="514" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC517" class="line" lang="python">            <span class="n" style="color: #333;">ntp</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">util</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">canonicalization_cache</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">mycache</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="518" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
518
</td>
<td class="diff-line-num new_line" data-linenumber="514" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
514
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC514" class="line" lang="python">            <span class="n" style="color: #333;">sockettemp</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">ntp</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">util</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">socket</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="519" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
519
</td>
<td class="diff-line-num new_line" data-linenumber="515" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
515
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC515" class="line" lang="python">            <span class="n" style="color: #333;">ntp</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">util</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">socket</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">fakesockmod</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="520" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
520
</td>
<td class="diff-line-num new_line old" data-linenumber="516" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC520" class="line" lang="python">            <span class="c" style="color: #998; font-style: italic;"># Test cache hit</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="521" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
521
</td>
<td class="diff-line-num new_line old" data-linenumber="516" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC521" class="line" lang="python">            <span class="k" style="font-weight: 600;">print</span><span class="p">(</span><span class="s" style="color: #d14;">"DNS:"</span><span class="p">,</span> <span class="n" style="color: #333;">f</span><span class="p">)</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="522" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
522
</td>
<td class="diff-line-num new_line old" data-linenumber="516" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC522" class="line" lang="python">            <span class="bp" style="color: #999;">self</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">assertEqual</span><span class="p">(</span><span class="n" style="color: #333;">f</span><span class="p">(</span><span class="s" style="color: #d14;">"foo"</span><span class="p">),</span> <span class="s" style="color: #d14;">"bar"</span><span class="p">)</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="523" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
523
</td>
<td class="diff-line-num new_line old" data-linenumber="516" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC523" class="line" lang="python">            <span class="bp" style="color: #999;">self</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">assertEqual</span><span class="p">(</span><span class="n" style="color: #333;">fakesockmod</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">gai_calls</span><span class="p">,</span> <span class="p">[])</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="524" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
524
</td>
<td class="diff-line-num new_line" data-linenumber="516" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
516
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC516" class="line" lang="python">            <span class="c" style="color: #998; font-style: italic;"># Test addrinfo fail</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="525" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
525
</td>
<td class="diff-line-num new_line" data-linenumber="517" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
517
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC517" class="line" lang="python">            <span class="n" style="color: #333;">fakesockmod</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">__init__</span><span class="p">()</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="526" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
526
</td>
<td class="diff-line-num new_line" data-linenumber="518" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
518
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC518" class="line" lang="python">            <span class="n" style="color: #333;">fakesockmod</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">gai_error_count</span> <span class="o" style="font-weight: 600;">=</span> <span class="mi" style="color: #099;">1</span></span>
</pre>
</td>
</tr>
<tr class="line_holder match" id="" style="line-height: 1.6;">
<td class="diff-line-num unfold js-unfold old_line" data-linenumber="539" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="diff-line-num unfold js-unfold new_line" data-linenumber="531" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="line_content match " style="padding-left: 0.5em; padding-right: 0.5em; color: rgba(0,0,0,0.3);" bgcolor="#fafafa">@@ -539,7 +531,6 @@ class TestPylibUtilMethods(unittest.TestCase):</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="539" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
539
</td>
<td class="diff-line-num new_line" data-linenumber="531" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
531
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC531" class="line" lang="python">            <span class="bp" style="color: #999;">self</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">assertEqual</span><span class="p">(</span><span class="n" style="color: #333;">f</span><span class="p">(</span><span class="s" style="color: #d14;">"bar:42"</span><span class="p">),</span> <span class="s" style="color: #d14;">"san.hastur.invalid:42"</span><span class="p">)</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="540" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
540
</td>
<td class="diff-line-num new_line" data-linenumber="532" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
532
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC532" class="line" lang="python">            <span class="c" style="color: #998; font-style: italic;"># Test nameinfo fail, no canonname</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="541" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
541
</td>
<td class="diff-line-num new_line" data-linenumber="533" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
533
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC533" class="line" lang="python">            <span class="n" style="color: #333;">fakesockmod</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">__init__</span><span class="p">()</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="542" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
542
</td>
<td class="diff-line-num new_line old" data-linenumber="534" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC542" class="line" lang="python">            <span class="n" style="color: #333;">mycache</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">__init__</span><span class="p">()</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="543" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
543
</td>
<td class="diff-line-num new_line" data-linenumber="534" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
534
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC534" class="line" lang="python">            <span class="n" style="color: #333;">fakesockmod</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">gni_error_count</span> <span class="o" style="font-weight: 600;">=</span> <span class="mi" style="color: #099;">1</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="544" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
544
</td>
<td class="diff-line-num new_line" data-linenumber="535" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
535
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC535" class="line" lang="python">            <span class="n" style="color: #333;">fakesockmod</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">gni_returns</span> <span class="o" style="font-weight: 600;">=</span> <span class="p">[(</span><span class="s" style="color: #d14;">"www.Hastur.invalid"</span><span class="p">,</span> <span class="mi" style="color: #099;">42</span><span class="p">)]</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="545" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
545
</td>
<td class="diff-line-num new_line" data-linenumber="536" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
536
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC536" class="line" lang="python">            <span class="n" style="color: #333;">fakesockmod</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">gai_returns</span> <span class="o" style="font-weight: 600;">=</span> <span class="p">[((</span><span class="s" style="color: #d14;">"family"</span><span class="p">,</span> <span class="s" style="color: #d14;">"socktype"</span><span class="p">,</span> <span class="s" style="color: #d14;">"proto"</span><span class="p">,</span></span>
</pre>
</td>
</tr>
<tr class="line_holder match" id="" style="line-height: 1.6;">
<td class="diff-line-num unfold js-unfold old_line" data-linenumber="547" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="diff-line-num unfold js-unfold new_line" data-linenumber="538" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="line_content match " style="padding-left: 0.5em; padding-right: 0.5em; color: rgba(0,0,0,0.3);" bgcolor="#fafafa">@@ -547,13 +538,11 @@ class TestPylibUtilMethods(unittest.TestCase):</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="547" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
547
</td>
<td class="diff-line-num new_line" data-linenumber="538" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
538
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC538" class="line" lang="python">            <span class="bp" style="color: #999;">self</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">assertEqual</span><span class="p">(</span><span class="n" style="color: #333;">f</span><span class="p">(</span><span class="s" style="color: #d14;">"bar:42"</span><span class="p">),</span> <span class="s" style="color: #d14;">"bar:42"</span><span class="p">)</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="548" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
548
</td>
<td class="diff-line-num new_line" data-linenumber="539" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
539
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC539" class="line" lang="python">            <span class="c" style="color: #998; font-style: italic;"># Test success</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="549" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
549
</td>
<td class="diff-line-num new_line" data-linenumber="540" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
540
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC540" class="line" lang="python">            <span class="n" style="color: #333;">fakesockmod</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">__init__</span><span class="p">()</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="550" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
550
</td>
<td class="diff-line-num new_line old" data-linenumber="541" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC550" class="line" lang="python">            <span class="n" style="color: #333;">mycache</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">__init__</span><span class="p">()</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="551" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
551
</td>
<td class="diff-line-num new_line" data-linenumber="541" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
541
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC541" class="line" lang="python">            <span class="n" style="color: #333;">fakesockmod</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">gni_returns</span> <span class="o" style="font-weight: 600;">=</span> <span class="p">[(</span><span class="s" style="color: #d14;">"www.Hastur.invalid"</span><span class="p">,</span> <span class="mi" style="color: #099;">42</span><span class="p">)]</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="552" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
552
</td>
<td class="diff-line-num new_line" data-linenumber="542" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
542
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC542" class="line" lang="python">            <span class="n" style="color: #333;">fakesockmod</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">gai_returns</span> <span class="o" style="font-weight: 600;">=</span> <span class="p">[((</span><span class="s" style="color: #d14;">"family"</span><span class="p">,</span> <span class="s" style="color: #d14;">"socktype"</span><span class="p">,</span> <span class="s" style="color: #d14;">"proto"</span><span class="p">,</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="553" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
553
</td>
<td class="diff-line-num new_line" data-linenumber="543" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
543
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC543" class="line" lang="python">                                         <span class="bp" style="color: #999;">None</span><span class="p">,</span> <span class="s" style="color: #d14;">"42.23.</span><span class="si" style="color: #d14;">%</span><span class="s" style="color: #d14;">$.(#"</span><span class="p">),)]</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="554" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
554
</td>
<td class="diff-line-num new_line" data-linenumber="544" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
544
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC544" class="line" lang="python">            <span class="bp" style="color: #999;">self</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">assertEqual</span><span class="p">(</span><span class="n" style="color: #333;">f</span><span class="p">(</span><span class="s" style="color: #d14;">"bar:42"</span><span class="p">),</span> <span class="s" style="color: #d14;">"www.hastur.invalid:42"</span><span class="p">)</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="555" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
555
</td>
<td class="diff-line-num new_line" data-linenumber="545" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
545
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC545" class="line" lang="python">        <span class="k" style="font-weight: 600;">finally</span><span class="p">:</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="556" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
556
</td>
<td class="diff-line-num new_line old" data-linenumber="546" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content noteable_line old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC556" class="line" lang="python">            <span class="n" style="color: #333;">ntp</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">util</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">canonicalization_cache</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">cachetemp</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="557" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
557
</td>
<td class="diff-line-num new_line" data-linenumber="546" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
546
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC546" class="line" lang="python">            <span class="n" style="color: #333;">ntp</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">util</span><span class="o" style="font-weight: 600;">.</span><span class="n" style="color: #333;">socket</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">sockettemp</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="558" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
558
</td>
<td class="diff-line-num new_line" data-linenumber="547" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
547
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC547" class="line" lang="python"></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="559" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
559
</td>
<td class="diff-line-num new_line" data-linenumber="548" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
548
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC548" class="line" lang="python">    <span class="k" style="font-weight: 600;">def</span> <span class="nf" style="color: #900; font-weight: 600;">test_termsize</span><span class="p">(</span><span class="bp" style="color: #999;">self</span><span class="p">):</span></span>
</pre>
</td>
</tr>

</table>
<br>
</li>

</div>
<div class="footer" style="margin-top: 10px;">
<p style="font-size: small; color: #777;">

<br>
<a href="https://gitlab.com/NTPsec/ntpsec/commit/9795f701fc82fb78698a962dddcbd025c933fcca">View it on GitLab</a>.
<br>
You're receiving this email because of your account on gitlab.com.
If you'd like to receive fewer emails, you can
adjust your notification settings.
<script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","action":{"@type":"ViewAction","name":"View Commit","url":"https://gitlab.com/NTPsec/ntpsec/commit/9795f701fc82fb78698a962dddcbd025c933fcca"}}</script>
</p>
</div>
</body>
</html>