diff options
Diffstat (limited to 'gnuradio-runtime/lib')
-rw-r--r-- | gnuradio-runtime/lib/buffer.cc | 4 | ||||
-rw-r--r-- | gnuradio-runtime/lib/local_sighandler.cc | 2 | ||||
-rw-r--r-- | gnuradio-runtime/lib/logger.cc | 5 | ||||
-rw-r--r-- | gnuradio-runtime/lib/prefs.cc | 3 | ||||
-rw-r--r-- | gnuradio-runtime/lib/sys_paths.cc | 5 | ||||
-rw-r--r-- | gnuradio-runtime/lib/vmcircbuf_mmap_shm_open.cc | 9 | ||||
-rw-r--r-- | gnuradio-runtime/lib/vmcircbuf_mmap_tmpfile.cc | 7 |
7 files changed, 14 insertions, 21 deletions
diff --git a/gnuradio-runtime/lib/buffer.cc b/gnuradio-runtime/lib/buffer.cc index 77c761085b..13f0a8c78b 100644 --- a/gnuradio-runtime/lib/buffer.cc +++ b/gnuradio-runtime/lib/buffer.cc @@ -341,11 +341,11 @@ void buffer_reader::get_tags_in_range(std::vector<tag_t>& v, uint64_t lower_bound = abs_start - d_attr_delay; // check for underflow and if so saturate at 0 if (lower_bound > abs_start) - lower_bound = 0; + lower_bound = 0; uint64_t upper_bound = abs_end - d_attr_delay; // check for underflow and if so saturate at 0 if (upper_bound > abs_end) - upper_bound = 0; + upper_bound = 0; v.clear(); std::multimap<uint64_t, tag_t>::iterator itr = diff --git a/gnuradio-runtime/lib/local_sighandler.cc b/gnuradio-runtime/lib/local_sighandler.cc index 7f96b2460d..ca16fe05e6 100644 --- a/gnuradio-runtime/lib/local_sighandler.cc +++ b/gnuradio-runtime/lib/local_sighandler.cc @@ -27,8 +27,8 @@ #include "local_sighandler.h" #include <stdio.h> #include <string.h> -#include <stdexcept> #include <boost/format.hpp> +#include <stdexcept> namespace gr { diff --git a/gnuradio-runtime/lib/logger.cc b/gnuradio-runtime/lib/logger.cc index 6b1ce7939b..63138851ee 100644 --- a/gnuradio-runtime/lib/logger.cc +++ b/gnuradio-runtime/lib/logger.cc @@ -263,10 +263,7 @@ void logger_add_file_appender(logger_ptr logger, { log4cpp::PatternLayout* layout = new log4cpp::PatternLayout(); log4cpp::Appender* app = - new log4cpp::FileAppender( - "FileAppender::" + filename, - filename, - append); + new log4cpp::FileAppender("FileAppender::" + filename, filename, append); layout->setConversionPattern(pattern); app->setLayout(layout); logger->setAppender(app); diff --git a/gnuradio-runtime/lib/prefs.cc b/gnuradio-runtime/lib/prefs.cc index 777d64211f..4173973c2e 100644 --- a/gnuradio-runtime/lib/prefs.cc +++ b/gnuradio-runtime/lib/prefs.cc @@ -102,7 +102,8 @@ void prefs::_read_files(const std::vector<std::string>& filenames) section = "default"; key = okey; } - std::transform(section.begin(), section.end(), section.begin(), ::tolower); + std::transform( + section.begin(), section.end(), section.begin(), ::tolower); std::transform(key.begin(), key.end(), key.begin(), ::tolower); // value of a basic_option is always a std::vector<string>; we only // allow single values, so: diff --git a/gnuradio-runtime/lib/sys_paths.cc b/gnuradio-runtime/lib/sys_paths.cc index 2f26724e7c..b9c3fc964f 100644 --- a/gnuradio-runtime/lib/sys_paths.cc +++ b/gnuradio-runtime/lib/sys_paths.cc @@ -73,12 +73,11 @@ std::string __userconf_path() boost::filesystem::path p; if (path) { p = path; - } - else { + } else { p = appdata_path(); p = p / ".gnuradio"; } - + return p.string(); } diff --git a/gnuradio-runtime/lib/vmcircbuf_mmap_shm_open.cc b/gnuradio-runtime/lib/vmcircbuf_mmap_shm_open.cc index 7d63dc08d1..da71aafc52 100644 --- a/gnuradio-runtime/lib/vmcircbuf_mmap_shm_open.cc +++ b/gnuradio-runtime/lib/vmcircbuf_mmap_shm_open.cc @@ -74,8 +74,8 @@ vmcircbuf_mmap_shm_open::vmcircbuf_mmap_shm_open(int size) : gr::vmcircbuf(size) // Where the "portable format" doesn't work, we try building // a full filesystem pathname pointing into a suitable temporary directory. - seg_name = str(boost::format("%s/gnuradio-%d-%d") % - gr::tmp_path() % getpid() % s_seg_counter); + seg_name = str(boost::format("%s/gnuradio-%d-%d") % gr::tmp_path() % + getpid() % s_seg_counter); } shm_fd = shm_open(seg_name.c_str(), O_RDWR | O_CREAT | O_EXCL, 0600); @@ -91,9 +91,8 @@ vmcircbuf_mmap_shm_open::vmcircbuf_mmap_shm_open(int size) : gr::vmcircbuf(size) EEXIST) // Named segment already exists (shouldn't happen). Try again continue; - static std::string msg = - str(boost::format("gr::vmcircbuf_mmap_shm_open: shm_open [%s]") % - seg_name); + static std::string msg = str( + boost::format("gr::vmcircbuf_mmap_shm_open: shm_open [%s]") % seg_name); perror(msg.c_str()); throw std::runtime_error("gr::vmcircbuf_mmap_shm_open"); } diff --git a/gnuradio-runtime/lib/vmcircbuf_mmap_tmpfile.cc b/gnuradio-runtime/lib/vmcircbuf_mmap_tmpfile.cc index f6c1777013..f7fd5e3d35 100644 --- a/gnuradio-runtime/lib/vmcircbuf_mmap_tmpfile.cc +++ b/gnuradio-runtime/lib/vmcircbuf_mmap_tmpfile.cc @@ -65,11 +65,8 @@ vmcircbuf_mmap_tmpfile::vmcircbuf_mmap_tmpfile(int size) : gr::vmcircbuf(size) // open a temporary file that we'll map in a bit later while (1) { - seg_name = str(boost::format( - "%s/gnuradio-%d-%d-XXXXXX") % - gr::tmp_path() % - getpid() % - s_seg_counter); + seg_name = str(boost::format("%s/gnuradio-%d-%d-XXXXXX") % gr::tmp_path() % + getpid() % s_seg_counter); s_seg_counter++; seg_fd = open(seg_name.c_str(), O_RDWR | O_CREAT | O_EXCL, 0600); |