<html lang='en'>
<head>
<meta content='text/html; charset=utf-8' http-equiv='Content-Type'>
<title>
GitLab
</title>
</meta>
</head>
<style>
  img {
    max-width: 100%;
    height: auto;
  }
  p.details {
    font-style:italic;
    color:#777
  }
  .footer p {
    font-size:small;
    color:#777
  }
  pre.commit-message {
    white-space: pre-wrap;
  }
  .file-stats a {
    text-decoration: none;
  }
  .file-stats .new-file {
    color: #090;
  }
  .file-stats .deleted-file {
    color: #B00;
  }
</style>
<body>
<div class='content'>
<h3>
Hal Murray 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/137a3db6a8c337c322f3c46505467d9c7531586d">137a3db6</a></strong>
<div>
<span>by Hal Murray</span>
<i>at 2016-01-15T14:36:28-08:00</i>
</div>
<pre class='commit-message'>Change gmtime to gmtime_r (last 2)</pre>
</li>
<li>
<strong><a href="https://gitlab.com/NTPsec/ntpsec/commit/5c551aa16d53f2cb6a6cab8c25df3dced7c3ca51">5c551aa1</a></strong>
<div>
<span>by Hal Murray</span>
<i>at 2016-01-15T15:03:30-08:00</i>
</div>
<pre class='commit-message'>Remove HAVE_PTHREAD_ATTR_*ETSTACKSIZE

Also fix bug in error handling.</pre>
</li>
</ul>
<h4>4 changed files:</h4>
<ul>
<li class='file-stats'>
<a href='#diff-0'>
libntp/work_thread.c
</a>
</li>
<li class='file-stats'>
<a href='#diff-1'>
ntpd/refclock_arc.c
</a>
</li>
<li class='file-stats'>
<a href='#diff-2'>
ntpd/refclock_dumbclock.c
</a>
</li>
<li class='file-stats'>
<a href='#diff-3'>
pylib/configure.py
</a>
</li>
</ul>
<h4>Changes:</h4>
<li id='diff-0'>
<a href='https://gitlab.com/NTPsec/ntpsec/compare/62dd53daa07bc8f83d3f38be796c7bd32e0c4871...5c551aa16d53f2cb6a6cab8c25df3dced7c3ca51#diff-0'>
<strong>
libntp/work_thread.c
</strong>
</a>
<hr>
<pre class="highlight"><code><span style="color: #000000;background-color: #ffdddd">--- a/libntp/work_thread.c
</span><span style="color: #000000;background-color: #ddffdd">+++ b/libntp/work_thread.c
</span><span style="color: #aaaaaa">@@ -453,24 +453,21 @@ start_blocking_thread_internal(
</span>   (*addremove_io_fd)(c->resp_read_pipe, c->ispipe, false);
        pthread_attr_init(&thr_attr);
        pthread_attr_setdetachstate(&thr_attr, PTHREAD_CREATE_DETACHED);
<span style="color: #000000;background-color: #ffdddd">-#if defined(HAVE_PTHREAD_ATTR_GETSTACKSIZE) && \
-    defined(HAVE_PTHREAD_ATTR_SETSTACKSIZE)
</span>   rc = pthread_attr_getstacksize(&thr_attr, &stacksize);
<span style="color: #000000;background-color: #ffdddd">-        if (-1 == rc) {
</span><span style="color: #000000;background-color: #ddffdd">+   if (0 != rc) {
+               errno = rc;
</span>           msyslog(LOG_ERR,
                        "start_blocking_thread: pthread_attr_getstacksize %m");
        } else if (stacksize < THREAD_MINSTACKSIZE) {
                rc = pthread_attr_setstacksize(&thr_attr,
                                               THREAD_MINSTACKSIZE);
<span style="color: #000000;background-color: #ffdddd">-                if (-1 == rc)
</span><span style="color: #000000;background-color: #ddffdd">+           if (0 != rc)
+                       errno = rc;
</span>                   msyslog(LOG_ERR,
                                "start_blocking_thread: pthread_attr_setstacksize(0x%lx -> 0x%lx) %m",
                                (u_long)stacksize,
                                (u_long)THREAD_MINSTACKSIZE);
        }
<span style="color: #000000;background-color: #ffdddd">-#else
-       UNUSED_ARG(stacksize);
-#endif
</span>   pthread_attr_setscope(&thr_attr, PTHREAD_SCOPE_SYSTEM);
        c->thread_ref = emalloc_zero(sizeof(*c->thread_ref));
        block_thread_signals(&saved_sig_mask);
</code></pre>

<br>
</li>
<li id='diff-1'>
<a href='https://gitlab.com/NTPsec/ntpsec/compare/62dd53daa07bc8f83d3f38be796c7bd32e0c4871...5c551aa16d53f2cb6a6cab8c25df3dced7c3ca51#diff-1'>
<strong>
ntpd/refclock_arc.c
</strong>
</a>
<hr>
<pre class="highlight"><code><span style="color: #000000;background-color: #ffdddd">--- a/ntpd/refclock_arc.c
</span><span style="color: #000000;background-color: #ddffdd">+++ b/ntpd/refclock_arc.c
</span><span style="color: #aaaaaa">@@ -1250,7 +1250,7 @@ arc_receive(
</span>   if(peer->ttl > 0) {
                if(pp->sloppyclockflag & CLK_FLAG1) {
                        struct tm  local;
<span style="color: #000000;background-color: #ffdddd">-                        struct tm *gmtp;
</span><span style="color: #000000;background-color: #ddffdd">+                   struct tm *gmtp, mygm;
</span>                   time_t     unixtime;
 
                        /*
<span style="color: #aaaaaa">@@ -1317,7 +1317,7 @@ arc_receive(
</span>                           break;
                        }
                        unixtime = mktime (&local);
<span style="color: #000000;background-color: #ffdddd">-                        if ((gmtp = gmtime (&unixtime)) == NULL)
</span><span style="color: #000000;background-color: #ddffdd">+                   if ((gmtp = gmtime_r (&unixtime, &mygm)) == NULL)
</span>                   {
                                pp->lencode = 0;
                                refclock_report (peer, CEVNT_FAULT);
</code></pre>

<br>
</li>
<li id='diff-2'>
<a href='https://gitlab.com/NTPsec/ntpsec/compare/62dd53daa07bc8f83d3f38be796c7bd32e0c4871...5c551aa16d53f2cb6a6cab8c25df3dced7c3ca51#diff-2'>
<strong>
ntpd/refclock_dumbclock.c
</strong>
</a>
<hr>
<pre class="highlight"><code><span style="color: #000000;background-color: #ffdddd">--- a/ntpd/refclock_dumbclock.c
</span><span style="color: #000000;background-color: #ddffdd">+++ b/ntpd/refclock_dumbclock.c
</span><span style="color: #aaaaaa">@@ -235,7 +235,7 @@ dumbclock_receive(
</span>   if (sscanf(pp->a_lastcode,"%02d:%02d:%02d",
                   &hours,&minutes,&seconds) == 3)
        {
<span style="color: #000000;background-color: #ffdddd">-            struct tm *gmtp;
</span><span style="color: #000000;background-color: #ddffdd">+       struct tm *gmtp, mygm;
</span>       struct tm *lt_p;
            struct tm tmbuf;
            time_t     asserted_time;        /* the SPM time based on the composite time+date */
<span style="color: #aaaaaa">@@ -289,7 +289,7 @@ dumbclock_receive(
</span>           return;
            }
 
<span style="color: #000000;background-color: #ffdddd">-            if ((gmtp = gmtime (&asserted_time)) == NULL)
</span><span style="color: #000000;background-color: #ddffdd">+       if ((gmtp = gmtime_r (&asserted_time, &mygm)) == NULL)
</span>       {
                refclock_report (peer, CEVNT_FAULT);
                return;
</code></pre>

<br>
</li>
<li id='diff-3'>
<a href='https://gitlab.com/NTPsec/ntpsec/compare/62dd53daa07bc8f83d3f38be796c7bd32e0c4871...5c551aa16d53f2cb6a6cab8c25df3dced7c3ca51#diff-3'>
<strong>
pylib/configure.py
</strong>
</a>
<hr>
<pre class="highlight"><code><span style="color: #000000;background-color: #ffdddd">--- a/pylib/configure.py
</span><span style="color: #000000;background-color: #ddffdd">+++ b/pylib/configure.py
</span><span style="color: #aaaaaa">@@ -244,8 +244,6 @@ def cmd_configure(ctx):
</span>           ('MD5Init', ["md5.h"], "CRYPTO"),
                ('ntp_adjtime', ["sys/time.h", "sys/timex.h"]),             # BSD
                ('ntp_gettime', ["sys/time.h", "sys/timex.h"]),             # BSD
<span style="color: #000000;background-color: #ffdddd">-                ('pthread_attr_getstacksize', ["pthread.h"], "PTHREAD"),
-               ('pthread_attr_setstacksize', ["pthread.h"], "PTHREAD"),
</span>           ('res_init', ["resolv.h"]),
                ("rtprio", ["sys/rtprio.h"]),               # Sun/BSD
                ('sched_setscheduler', ["sched.h"]),
</code></pre>

<br>
</li>

</div>
<div class='footer' style='margin-top: 10px;'>
<p>

<br>
<a href="https://gitlab.com/NTPsec/ntpsec/compare/62dd53daa07bc8f83d3f38be796c7bd32e0c4871...5c551aa16d53f2cb6a6cab8c25df3dced7c3ca51">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.

</p>
</div>
</body>
</html>