Skip to content

Mainline doesn't build #113

Closed
Closed
@a1exeyk

Description

@a1exeyk

make all fails with error (-Werror)

cc -pedantic -Wall -Werror -Wimplicit -Wunused -Wcomment -Wchar-subscripts -Wuninitialized -Wshadow -Wcast-qual -Wcast-align -Wwrite-strings -Wstack-protector -fPIC -std=c99 -D_POSIX_C_SOURCE=200112L -fstack-protector-all -O2 -I../libcrypto-root/include/ -I../api/ -I../ -Wno-deprecated-declarations -Wno-unknown-pragmas -Wformat-security -D_FORTIFY_SOURCE=2   -c -o s2n_server_extensions.o s2n_server_extensions.c
cc1: warnings being treated as errors
s2n_server_extensions.c: In function ‘s2n_server_recv_alpn’:
s2n_server_extensions.c:116: warning: comparison is always false due to limited range of data type

Compiler is valid as uint8_t is compared with size_t:

if (protocol_len > sizeof(conn->application_protocol) - 1) {

My system and compiler are pretty outdated. So feel free to close if that's not an issue with modern gcc.

$ uname -sp
Linux x86_64
$ gcc --version
gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-54)
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions