From c2ccd3d1d2f3af1b41e81ca680bc07d85430facc Mon Sep 17 00:00:00 2001 From: Raphael Dumusc Date: Fri, 19 May 2017 14:51:54 +0200 Subject: [PATCH] Removed legacy warning about ',' separator in URIs --- .gitexternals | 2 +- CMakeLists.txt | 10 +++++----- doc/Changelog.md | 4 +++- servus/CMakeLists.txt | 3 --- servus/uri.cpp | 19 ------------------- 5 files changed, 9 insertions(+), 29 deletions(-) diff --git a/.gitexternals b/.gitexternals index 28ecb16..8f6f437 100644 --- a/.gitexternals +++ b/.gitexternals @@ -1,2 +1,2 @@ # -*- mode: cmake -*- -# CMake/common https://github.com/Eyescale/CMake.git 57c465e +# CMake/common https://github.com/Eyescale/CMake.git 71654f7 diff --git a/CMakeLists.txt b/CMakeLists.txt index 2751c0c..6165075 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -17,7 +17,7 @@ # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. cmake_minimum_required(VERSION 3.1 FATAL_ERROR) -project(Servus VERSION 1.5.0) +project(Servus VERSION 1.5.1) set(Servus_VERSION_ABI 5) list(APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/CMake @@ -27,9 +27,8 @@ include(GitExternal) set(SERVUS_DESCRIPTION "C++ network oriented utilities including a zeroconf implementation") set(SERVUS_MAINTAINER "Human Brain Project ") -set(CPACK_PACKAGE_LICENSE LGPL) -set(COMMON_PROJECT_DOMAIN eu.humanbrainproject) -set(SERVUS_DEB_DEPENDS libboost-test-dev avahi-daemon libavahi-client-dev) +set(SERVUS_LICENSE LGPL) +set(SERVUS_DEB_DEPENDS avahi-daemon libavahi-client-dev libboost-test-dev) include(Common) @@ -38,7 +37,7 @@ if(LINUX) else() common_find_package(DNSSD) endif() -common_find_package(Boost 1.51 COMPONENTS unit_test_framework regex) +common_find_package(Boost 1.51 COMPONENTS unit_test_framework) common_find_package(Qt5Core) common_find_package(Qt5Widgets) common_find_package(Threads REQUIRED) @@ -53,6 +52,7 @@ add_subdirectory(apps) add_subdirectory(tests) include(CPackConfig) +set(COMMON_PROJECT_DOMAIN eu.humanbrainproject) set(DOXYGEN_EXTRA_INPUT ${PROJECT_SOURCE_DIR}/README.md) set(DOXYGEN_MAINPAGE_MD README.md) include(DoxygenRule) # must be after all targets diff --git a/doc/Changelog.md b/doc/Changelog.md index 3dedd5f..167cdc4 100644 --- a/doc/Changelog.md +++ b/doc/Changelog.md @@ -1,8 +1,10 @@ # Changelog {#Changelog} -# git master +# Release 1.5.1 (git master) +* [72](https://github.com/HBPVis/Servus/pull/72): + Removed legacy warning about ',' separator in URIs. * [71](https://github.com/HBPVis/Servus/pull/71): Proper filtering for local services based on Avahi provided flags. * [68](https://github.com/HBPVis/Servus/pull/68): diff --git a/servus/CMakeLists.txt b/servus/CMakeLists.txt index 7bd4927..ea583e0 100644 --- a/servus/CMakeLists.txt +++ b/servus/CMakeLists.txt @@ -50,9 +50,6 @@ endif() if(AVAHI-CLIENT_FOUND) list(APPEND SERVUS_LINK_LIBRARIES ${avahi-client_LIBRARIES}) endif() -if(BOOST_FOUND) - list(APPEND SERVUS_LINK_LIBRARIES PRIVATE ${Boost_REGEX_LIBRARY}) -endif() set(SERVUS_OMIT_LIBRARY_HEADER ON) common_library(Servus) diff --git a/servus/uri.cpp b/servus/uri.cpp index 9a762a1..c09ee47 100644 --- a/servus/uri.cpp +++ b/servus/uri.cpp @@ -27,10 +27,6 @@ #include #include -#ifdef SERVUS_USE_BOOST -#include -#endif - namespace servus { namespace @@ -147,26 +143,11 @@ void _parseAuthority(URIData& data, const std::string& auth) throw std::invalid_argument(""); } -#ifdef SERVUS_USE_BOOST -void _warnAboutLegacySeparator(const std::string& query) -{ - const boost::regex legacySeparator("[^&]*,[^&]*="); - if (boost::regex_search(query, legacySeparator)) - std::cerr << "servus::URI: Detected legacy ',' separator in query: \"" - << query << "\". Use '&' separator instead." << std::endl; -} -#endif - void _parseQueryMap(URIData& data) { // parse query data into key-value pairs std::string query = data.query; -#ifdef SERVUS_USE_BOOST - // warn if a query uses the legacy ',' separator instead of '&' - _warnAboutLegacySeparator(query); -#endif - data.queryMap.clear(); while (!query.empty()) {