aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--coreutils/md5_sha1_sum.c12
-rw-r--r--libbb/makedev.c5
2 files changed, 9 insertions, 8 deletions
diff --git a/coreutils/md5_sha1_sum.c b/coreutils/md5_sha1_sum.c
index c81619493..8690f4017 100644
--- a/coreutils/md5_sha1_sum.c
+++ b/coreutils/md5_sha1_sum.c
@@ -33,8 +33,8 @@ static uint8_t *hash_file(const char *filename, hash_algo_t hash_algo)
33 } context; 33 } context;
34 uint8_t *hash_value = NULL; 34 uint8_t *hash_value = NULL;
35 RESERVE_CONFIG_UBUFFER(in_buf, 4096); 35 RESERVE_CONFIG_UBUFFER(in_buf, 4096);
36 void (*update)(const void*, size_t, void*); 36 void FAST_FUNC (*update)(const void*, size_t, void*);
37 void (*final)(void*, void*); 37 void FAST_FUNC (*final)(void*, void*);
38 38
39 src_fd = open_or_warn_stdin(filename); 39 src_fd = open_or_warn_stdin(filename);
40 if (src_fd < 0) { 40 if (src_fd < 0) {
@@ -44,13 +44,13 @@ static uint8_t *hash_file(const char *filename, hash_algo_t hash_algo)
44 /* figure specific hash algorithims */ 44 /* figure specific hash algorithims */
45 if (ENABLE_MD5SUM && hash_algo==HASH_MD5) { 45 if (ENABLE_MD5SUM && hash_algo==HASH_MD5) {
46 md5_begin(&context.md5); 46 md5_begin(&context.md5);
47 update = (void (*)(const void*, size_t, void*))md5_hash; 47 update = (void*)md5_hash;
48 final = (void (*)(void*, void*))md5_end; 48 final = (void*)md5_end;
49 hash_len = 16; 49 hash_len = 16;
50 } else if (ENABLE_SHA1SUM && hash_algo==HASH_SHA1) { 50 } else if (ENABLE_SHA1SUM && hash_algo==HASH_SHA1) {
51 sha1_begin(&context.sha1); 51 sha1_begin(&context.sha1);
52 update = (void (*)(const void*, size_t, void*))sha1_hash; 52 update = (void*)sha1_hash;
53 final = (void (*)(void*, void*))sha1_end; 53 final = (void*)sha1_end;
54 hash_len = 20; 54 hash_len = 20;
55 } else { 55 } else {
56 bb_error_msg_and_die("algorithm not supported"); 56 bb_error_msg_and_die("algorithm not supported");
diff --git a/libbb/makedev.c b/libbb/makedev.c
index efd51224f..ca71fdba6 100644
--- a/libbb/makedev.c
+++ b/libbb/makedev.c
@@ -7,6 +7,7 @@
7 */ 7 */
8 8
9/* We do not include libbb.h - #define makedev() is there! */ 9/* We do not include libbb.h - #define makedev() is there! */
10#include "platform.h"
10#include <features.h> 11#include <features.h>
11#include <sys/sysmacros.h> 12#include <sys/sysmacros.h>
12 13
@@ -15,8 +16,8 @@
15/* uclibc people please check - do we need "&& !__UCLIBC__" above? */ 16/* uclibc people please check - do we need "&& !__UCLIBC__" above? */
16 17
17/* suppress gcc "no previous prototype" warning */ 18/* suppress gcc "no previous prototype" warning */
18unsigned long long bb_makedev(unsigned int major, unsigned int minor); 19unsigned long long FAST_FUNC bb_makedev(unsigned int major, unsigned int minor);
19unsigned long long bb_makedev(unsigned int major, unsigned int minor) 20unsigned long long FAST_FUNC bb_makedev(unsigned int major, unsigned int minor)
20{ 21{
21 return makedev(major, minor); 22 return makedev(major, minor);
22} 23}