From e73c25fb9226029f0e50052b1ffacedb3a78622b Mon Sep 17 00:00:00 2001 From: Josh Blum Date: Mon, 24 Jan 2011 00:34:28 -0800 Subject: gruel thread simplification: Removed get_new_timeout from thread.h (usrp2_vrt carryover) Basically it was created because of a misunderstanding of the time types; and its only ever called once. This also removes thread.cc Call posix_time::milliseconds in usrp2 control.cc. Notice that it passes a time_duration rather than a ptime (aka system time). Added #include to gr_buffer.h. It turns out that boost posix_time.hpp implicitly included the deque header which was missing from gr_buffer.h Replaced the include for thread.hpp with only the includes for the boost thread types mentioned in gruel/thread.h. Also, making use of the scoped_lock typedef that comes with boost thread locks. boost 3.5 safe. --- gruel/src/lib/thread.cc | 35 ----------------------------------- 1 file changed, 35 deletions(-) delete mode 100644 gruel/src/lib/thread.cc (limited to 'gruel/src/lib/thread.cc') diff --git a/gruel/src/lib/thread.cc b/gruel/src/lib/thread.cc deleted file mode 100644 index d8f77b506..000000000 --- a/gruel/src/lib/thread.cc +++ /dev/null @@ -1,35 +0,0 @@ -/* -*- c++ -*- */ -/* - * Copyright 2010 Free Software Foundation, Inc. - * - * This file is part of GNU Radio - * - * GNU Radio is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 3, or (at your option) - * any later version. - * - * GNU Radio is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License along - * with this program; if not, write to the Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - */ - -#ifdef HAVE_CONFIG_H -#include -#endif -#include - -namespace gruel { - - boost::system_time - get_new_timeout(double secs) - { - return boost::get_system_time() + boost::posix_time::milliseconds(long(secs*1e3)); - } - -} -- cgit