Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[2.1.3] sha1.c: compiler warning regarding array bounds #13192

Closed
UweSauter opened this issue Mar 11, 2022 · 3 comments
Closed

[2.1.3] sha1.c: compiler warning regarding array bounds #13192

UweSauter opened this issue Mar 11, 2022 · 3 comments

Comments

@UweSauter
Copy link

During compilation on a Raspberry Pi 4 with Arch Linux and GCC 11.2.0 I see

  CC       algs/modes/ccm.lo
  CC       algs/modes/ecb.lo
  CC       algs/sha1/sha1.lo
../../module/icp/algs/sha1/sha1.c:422:44: warning: argument 2 of type ‘const uint8_t[64]’ {aka ‘const unsigned char[64]’} with mismatched bound [-Warray-parameter=]
  422 | SHA1Transform(SHA1_CTX *ctx, const uint8_t blk[64])
      |                              ~~~~~~~~~~~~~~^~~~~~~
../../module/icp/algs/sha1/sha1.c:69:39: note: previously declared as ‘const uint8_t *’ {aka ‘const unsigned char *’}
   69 | static void SHA1Transform(SHA1_CTX *, const uint8_t *);
      |                                       ^~~~~~~~~~~~~~~
  CC       algs/sha2/sha2.lo
  CC       algs/skein/skein.lo

Haven't checked on other platforms.

@UweSauter
Copy link
Author

Hm, looks like master doesn't contain that file any more.

@nabijaczleweli
Copy link
Contributor

Yeah, nothing actually used it, so it got removed – see a798b48 (#12902). This is 100% dead code, even in 2.1.3 (and that warning is benign anyway, since those prototypes are the same).

@UweSauter
Copy link
Author

As this file is removed in master, there is nothing more to do here…

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants