From: Brad King Date: Thu, 22 Oct 2015 13:42:23 +0000 (-0400) Subject: Avoid non-portable u_int8_t X-Git-Tag: v3.1.900a~47 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a2004af24792f785a2eb67d4faf85c606851fd44;p=thirdparty%2Flibarchive.git Avoid non-portable u_int8_t Use uint8_t that we prepare in config.h instead. --- diff --git a/libarchive/archive_random.c b/libarchive/archive_random.c index 57c49d5ab..b162ff3ae 100644 --- a/libarchive/archive_random.c +++ b/libarchive/archive_random.c @@ -133,9 +133,9 @@ archive_random(void *buf, size_t nbytes) #endif /* !__GNUC__ */ struct arc4_stream { - u_int8_t i; - u_int8_t j; - u_int8_t s[256]; + uint8_t i; + uint8_t j; + uint8_t s[256]; }; static pthread_mutex_t arc4random_mtx = PTHREAD_MUTEX_INITIALIZER; @@ -155,7 +155,7 @@ static struct arc4_stream rs; static pid_t arc4_stir_pid; static int arc4_count; -static inline u_int8_t arc4_getbyte(void); +static inline uint8_t arc4_getbyte(void); static void arc4_stir(void); static inline void @@ -173,7 +173,7 @@ static inline void arc4_addrandom(u_char *dat, int datlen) { int n; - u_int8_t si; + uint8_t si; rs.i--; for (n = 0; n < 256; n++) { @@ -235,10 +235,10 @@ arc4_stir_if_needed(void) } } -static inline u_int8_t +static inline uint8_t arc4_getbyte(void) { - u_int8_t si, sj; + uint8_t si, sj; rs.i = (rs.i + 1); si = rs.s[rs.i];