Commit af96399b authored by Alessandro Rubini's avatar Alessandro Rubini

unix-socket: bugfix: T2 was UTC not TAI

For some reason (I don't rememeber why), RX timestamps are retrieved
from the socket, while TX timestamps are with tops->get.

Thus, there was no utc/tai correction on receive stamps (i.e. T2).
This affects us when we are driven by a WR switch, that properly
differentiates between UTC and TAI.
Signed-off-by: Alessandro Rubini's avatarAlessandro Rubini <rubini@gnudd.com>
parent 8ddfbcec
......@@ -77,7 +77,7 @@ static int unix_recv_msg(struct pp_instance *ppi, int fd, void *pkt, int len,
}
if (tv) {
t->seconds = tv->tv_sec;
t->seconds = tv->tv_sec + DSPRO(ppi)->currentUtcOffset;
t->nanoseconds = tv->tv_usec * 1000;
t->correct = 1;
} else {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment