]> git.ipfire.org Git - thirdparty/lxc.git/commit
utils: Fix wrong integer of a function parameter. 3113/head
authorJulio Faracco <jcfaracco@gmail.com>
Sat, 3 Aug 2019 05:16:13 +0000 (02:16 -0300)
committerJulio Faracco <jcfaracco@gmail.com>
Sat, 3 Aug 2019 05:16:13 +0000 (02:16 -0300)
commit7c3d3976fa4036fe5c260ca3a68376360e98e260
tree41fed45e2a421fbb86e43dc38ecaade87fa150b7
parentdf78878351774b2fd4d9a34b43ea9cb08e425e31
utils: Fix wrong integer of a function parameter.

If SSL is enabled, utils will include function `do_sha1_hash()` to
generate a sha1 encrypted buffer. Last function argument of
`EVP_DigestFinal_ex()` requires a `unsigned int` but the current
parameter is an `integer` type.

See error:
utils.c:350:38: error: passing 'int *' to parameter of type 'unsigned int *' converts between pointers to integer types with different sign
      [-Werror,-Wpointer-sign]
        EVP_DigestFinal_ex(mdctx, md_value, md_len);
                                            ^~~~~~
/usr/include/openssl/evp.h:549:49: note: passing argument to parameter 's' here
                                  unsigned int *s);

Signed-off-by: Julio Faracco <jcfaracco@gmail.com>
src/lxc/lxccontainer.c
src/lxc/utils.c
src/lxc/utils.h