aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGarrett D'Amore <garrett@damore.org>2018-05-16 10:52:55 -0700
committerGarrett D'Amore <garrett@damore.org>2018-05-16 11:42:06 -0700
commitec84c5a8406bb203d5f8830e280f93cf1f63cd6a (patch)
tree740fb689639e5f3a6b5bda849af4aed3e63659c4
parent84c32ea006f01f10cea335a9b152ec68714f46c9 (diff)
downloadnng-ec84c5a8406bb203d5f8830e280f93cf1f63cd6a.tar.gz
nng-ec84c5a8406bb203d5f8830e280f93cf1f63cd6a.tar.bz2
nng-ec84c5a8406bb203d5f8830e280f93cf1f63cd6a.zip
Switch to clang 6 and gcc 8 on xenial for circle ci.
We also fixed some warnings found by gcc8.
-rw-r--r--.circleci/config.yml26
-rw-r--r--src/core/panic.c4
-rw-r--r--tests/httpserver.c6
3 files changed, 17 insertions, 19 deletions
diff --git a/.circleci/config.yml b/.circleci/config.yml
index a5adab5f..2a2707c8 100644
--- a/.circleci/config.yml
+++ b/.circleci/config.yml
@@ -8,27 +8,27 @@ jobs:
docker:
- image: ubuntu:16.04
environment:
- CC: clang-4.0
- CXX: clang++-4.0
- CLANG_FORMAT: clang-format-4.0
+ CC: clang-6.0
+ CXX: clang++-6.0
+ CLANG_FORMAT: clang-format-6.0
CTEST_OUTPUT_ON_FAILURE: 1
steps:
- checkout
- run: apt-get update -qq
- run: apt-get install -y software-properties-common
# llvm apt details: https://apt.llvm.org
- - run: apt-add-repository "deb http://apt.llvm.org/xenial/ llvm-toolchain-xenial-4.0 main"
+ - run: apt-add-repository "deb http://apt.llvm.org/xenial/ llvm-toolchain-xenial-6.0 main"
- run: apt-get update -qq
- run: >
- apt-get install -y
+ apt-get install -y --allow-unauthenticated
build-essential
curl
asciidoctor
cmake
libmbedtls-dev
ninja-build
- clang-4.0
- clang-format-4.0
+ clang-6.0
+ clang-format-6.0
- run: ./etc/format-check.sh
- run: ./.circleci/build-and-test.sh
@@ -36,10 +36,10 @@ jobs:
docker:
- image: ubuntu:16.04
environment:
- CC: gcc-7
- CXX: g++-7
+ CC: gcc-8
+ CXX: g++-8
COVERAGE: "ON"
- GCOV: gcov-7
+ GCOV: gcov-8
steps:
- checkout
- run: apt-get update -qq
@@ -47,15 +47,15 @@ jobs:
- run: add-apt-repository ppa:ubuntu-toolchain-r/test
- run: apt-get update -qq
- run: >
- apt-get install -y
+ apt-get install -y --allow-unauthenticated
build-essential
curl
asciidoctor
cmake
libmbedtls-dev
ninja-build
- gcc-7
- g++-7
+ gcc-8
+ g++-8
- run: ./.circleci/build-and-test.sh
- run: ./etc/codecov.sh
diff --git a/src/core/panic.c b/src/core/panic.c
index ff621a59..7b434f91 100644
--- a/src/core/panic.c
+++ b/src/core/panic.c
@@ -48,8 +48,8 @@ nni_show_backtrace(void)
void
nni_panic(const char *fmt, ...)
{
- char buf[128];
- char fbuf[128];
+ char buf[100];
+ char fbuf[93]; // 7 bytes of "panic: "
va_list va;
va_start(va, fmt);
diff --git a/tests/httpserver.c b/tests/httpserver.c
index acbe237a..fb8e300e 100644
--- a/tests/httpserver.c
+++ b/tests/httpserver.c
@@ -17,8 +17,8 @@
// Basic HTTP server tests.
#include "core/nng_impl.h"
-#include "supplemental/tls/tls.h"
#include "supplemental/http/http.h"
+#include "supplemental/tls/tls.h"
const char *doc1 = "<html><body>Someone <b>is</b> home!</body</html>";
const char *doc2 = "This is a text file.";
@@ -157,7 +157,6 @@ fail:
}
TestMain("HTTP Server", {
-
nng_http_server * s;
nng_http_handler *h;
@@ -167,7 +166,7 @@ TestMain("HTTP Server", {
Convey("We can start an HTTP server", {
nng_aio *aio;
char portbuf[16];
- char urlstr[32];
+ char urlstr[48];
nng_url *url;
trantest_next_address(portbuf, "%u");
@@ -445,6 +444,5 @@ TestMain("HTTP Server", {
nng_http_res_free(res);
nng_url_free(curl);
});
-
});
})