From 1b5ae78a956b7f534b3b85ff9676651eb8d21485 Mon Sep 17 00:00:00 2001 From: oliverschmidt Date: Thu, 20 Dec 2007 20:30:55 +0000 Subject: [PATCH] Easily avoided double (meant to be a forward ?) definition of timesynch_driver. --- core/sys/timesynch.c | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/core/sys/timesynch.c b/core/sys/timesynch.c index 13ca56a61..ed688ba9e 100644 --- a/core/sys/timesynch.c +++ b/core/sys/timesynch.c @@ -34,7 +34,7 @@ * * This file is part of the Contiki operating system. * - * $Id: timesynch.c,v 1.2 2007/12/16 14:48:33 adamdunkels Exp $ + * $Id: timesynch.c,v 1.3 2007/12/20 20:30:55 oliverschmidt Exp $ */ /** @@ -49,7 +49,6 @@ #include "net/rime.h" #include "dev/simple-cc2420.h" -static const struct mac_driver timesynch_driver; static const struct mac_driver *mac; static void (* receiver_callback)(const struct mac_driver *); @@ -96,14 +95,6 @@ send(void) } /*---------------------------------------------------------------------------*/ static void -input(const struct mac_driver *d) -{ - if(receiver_callback) { - receiver_callback(×ynch_driver); - } -} -/*---------------------------------------------------------------------------*/ -static void adjust_offset(rtimer_clock_t authoritative_time, rtimer_clock_t local_time) { offset = offset + authoritative_time - local_time; @@ -161,6 +152,14 @@ static const struct mac_driver timesynch_driver = { off, }; /*---------------------------------------------------------------------------*/ +static void +input(const struct mac_driver *d) +{ + if(receiver_callback) { + receiver_callback(×ynch_driver); + } +} +/*---------------------------------------------------------------------------*/ const struct mac_driver * timesynch_init(const struct mac_driver *d) {