[lxc-devel] [lxc/lxc] 7c3d39: utils: Fix wrong integer of a function parameter.

Christian Brauner noreply at github.com
Sat Aug 3 14:33:32 UTC 2019


  Branch: refs/heads/master
  Home:   https://github.com/lxc/lxc
  Commit: 7c3d3976fa4036fe5c260ca3a68376360e98e260
      https://github.com/lxc/lxc/commit/7c3d3976fa4036fe5c260ca3a68376360e98e260
  Author: Julio Faracco <jcfaracco at gmail.com>
  Date:   2019-08-03 (Sat, 03 Aug 2019)

  Changed paths:
    M src/lxc/lxccontainer.c
    M src/lxc/utils.c
    M src/lxc/utils.h

  Log Message:
  -----------
  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 at gmail.com>


  Commit: 2ffda4c4f11bf054ac3da3f9bdae032063d4397b
      https://github.com/lxc/lxc/commit/2ffda4c4f11bf054ac3da3f9bdae032063d4397b
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2019-08-03 (Sat, 03 Aug 2019)

  Changed paths:
    M src/lxc/lxccontainer.c
    M src/lxc/utils.c
    M src/lxc/utils.h

  Log Message:
  -----------
  Merge pull request #3113 from jcfaracco/clang

utils: Fix wrong integer of a function parameter.


Compare: https://github.com/lxc/lxc/compare/df7887835177...2ffda4c4f11b


More information about the lxc-devel mailing list