Skip to content
This repository was archived by the owner on Nov 6, 2022. It is now read-only.
This repository was archived by the owner on Nov 6, 2022. It is now read-only.

http_parser.c:35:24: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare] #471

@nxhack

Description

@nxhack

Version : 2.9.1

OS: OpenWrt
ARCH: mips 24kc (32bit)
Compiler: gcc-7.4.0

http_parser.c: In function 'http_parser_execute':
http_parser.c:35:24: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]
 # define MIN(a,b) ((a) < (b) ? (a) : (b))
                        ^
http_parser.c:1500:41: note: in expansion of macro 'MIN'
                 const char* limit = p + MIN(data + len - p, max_header_size);
                                         ^~~
http_parser.c:35:36: error: signed and unsigned type in conditional expression [-Werror=sign-compare]
 # define MIN(a,b) ((a) < (b) ? (a) : (b))
                                    ^
http_parser.c:1500:41: note: in expansion of macro 'MIN'
                 const char* limit = p + MIN(data + len - p, max_header_size);
                                         ^~~
cc1: all warnings being treated as errors

There is no problem with version 2.9.0

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