diff --git a/CMakeLists.txt b/CMakeLists.txt index d7b01087..6853e2c8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -135,7 +135,7 @@ else( WIN32 ) # Apple AND Linux endif( APPLE ) if( "${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU" ) - set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fno-builtin-memcmp -Wno-class-memaccess -Wno-parentheses -Wno-terminate -Wno-invalid-offsetof" ) + set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fno-builtin-memcmp -Wno-parentheses -Wno-invalid-offsetof" ) elseif( "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang" ) if( CMAKE_CXX_COMPILER_VERSION VERSION_EQUAL 4.0.0 OR CMAKE_CXX_COMPILER_VERSION VERSION_GREATER 4.0.0 ) set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-invalid-partial-specialization" ) diff --git a/libraries/app/config_util.cpp b/libraries/app/config_util.cpp index f06291b7..fd011995 100644 --- a/libraries/app/config_util.cpp +++ b/libraries/app/config_util.cpp @@ -151,7 +151,7 @@ static fc::optional load_logging_config_from_ini_file(const fc::console_appender::level_color(fc::log_level::error, fc::console_appender::color::cyan)); console_appender_config.stream = fc::variant(stream_name).as(GRAPHENE_MAX_NESTED_OBJECTS); - logging_config.appenders.push_back(fc::appender_config(console_appender_name, "console", fc::variant(console_appender_config, GRAPHENE_MAX_NESTED_OBJECTS))); + logging_config.appenders.push_back(fc::appender_config(console_appender_name, "console", fc::variant(console_appender_config))); found_logging_config = true; } else if (boost::starts_with(section_name, file_appender_section_prefix)) diff --git a/programs/witness_node/main.cpp b/programs/witness_node/main.cpp index f7d2774c..2b3ab13a 100644 --- a/programs/witness_node/main.cpp +++ b/programs/witness_node/main.cpp @@ -36,28 +36,18 @@ #include //#include -#include #include #include -#include -#include -#include -#include #include - #include -#include -#include -#include -#include +#include +#include #include -#include #include #include -#include #ifdef WIN32 # include @@ -68,9 +58,6 @@ using namespace graphene; namespace bpo = boost::program_options; -void write_default_logging_config_to_stream(std::ostream& out); -fc::optional load_logging_config_from_ini_file(const fc::path& config_ini_filename); - int main(int argc, char** argv) { app::application* node = new app::application(); fc::oexception unhandled_exception; @@ -192,7 +179,7 @@ int main(int argc, char** argv) { node->shutdown_plugins(); node->shutdown(); delete node; - return 0; + return EXIT_SUCCESS; } catch( const fc::exception& e ) { // deleting the node can yield, so do this outside the exception handler unhandled_exception = e; @@ -203,7 +190,7 @@ int main(int argc, char** argv) { elog("Exiting with error:\n${e}", ("e", unhandled_exception->to_detail_string())); node->shutdown(); delete node; - return 1; + return EXIT_FAILURE; } }