]> granicus.if.org Git - libevent/commit
http: suppress "flags may be used uninitialized in this function" error
authorAzat Khuzhin <azat@libevent.org>
Sat, 9 Jul 2022 14:17:38 +0000 (17:17 +0300)
committerAzat Khuzhin <azat@libevent.org>
Sat, 9 Jul 2022 14:36:13 +0000 (17:36 +0300)
commitc8501afc0cde1a1d8f95daf293ea9fc7feff6e59
treeffa35215b95f941a687524eff7adfb5ddbfc4b81
parent3960449374595248577fa916dc1a40f49badd03f
http: suppress "flags may be used uninitialized in this function" error

Some GCC reports [1]:

    /home/runner/work/libevent/libevent/http.c: In function ‘evhttp_make_header’:
    /home/runner/work/libevent/libevent/http.c:503:14: error: ‘flags’ may be used uninitialized in this function [-Werror=maybe-uninitialized]
      ev_uint16_t flags;
                  ^~~~~
    /home/runner/work/libevent/libevent/http.c: In function ‘evhttp_get_body’:
    /home/runner/work/libevent/libevent/http.c:2354:14: error: ‘flags’ may be used uninitialized in this function [-Werror=maybe-uninitialized]
      ev_uint16_t flags;
                  ^~~~~
  [1]: https://github.com/libevent/libevent/runs/7263518338?check_suite_focus=true#logs
http.c