summaryrefslogtreecommitdiff
path: root/src/experimental/blowfish.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/experimental/blowfish.h')
-rw-r--r--src/experimental/blowfish.h22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/experimental/blowfish.h b/src/experimental/blowfish.h
index fb46dfd..054fc82 100644
--- a/src/experimental/blowfish.h
+++ b/src/experimental/blowfish.h
@@ -29,24 +29,24 @@ namespace Bu
29 using Bu::Stream::write; 29 using Bu::Stream::write;
30 30
31 private: 31 private:
32 unsigned int PA[NUM_SUBKEYS]; 32 uint32_t PA[NUM_SUBKEYS];
33 unsigned int SB[NUM_S_BOXES][NUM_ENTRIES]; 33 uint32_t SB[NUM_S_BOXES][NUM_ENTRIES];
34 34
35#if __BYTE_ORDER == __BIG_ENDIAN 35#if __BYTE_ORDER == __BIG_ENDIAN
36 struct WordByte 36 struct WordByte
37 { 37 {
38 unsigned int zero:8; 38 uint32_t zero:8;
39 unsigned int one:8; 39 uint32_t one:8;
40 unsigned int two:8; 40 uint32_t two:8;
41 unsigned int three:8; 41 uint32_t three:8;
42 }; 42 };
43#elif __BYTE_ORDER == __LITTLE_ENDIAN 43#elif __BYTE_ORDER == __LITTLE_ENDIAN
44 struct WordByte 44 struct WordByte
45 { 45 {
46 unsigned int three:8; 46 uint32_t three:8;
47 unsigned int two:8; 47 uint32_t two:8;
48 unsigned int one:8; 48 uint32_t one:8;
49 unsigned int zero:8; 49 uint32_t zero:8;
50 }; 50 };
51#else 51#else
52#error No endianness defined 52#error No endianness defined
@@ -54,7 +54,7 @@ namespace Bu
54 54
55 union Word 55 union Word
56 { 56 {
57 unsigned int word; 57 uint32_t word;
58 WordByte byte; 58 WordByte byte;
59 }; 59 };
60 60