diff options
author | Haru <haru@dotalux.com> | 2016-03-13 19:47:35 +0100 |
---|---|---|
committer | Haru <haru@dotalux.com> | 2016-07-12 20:58:32 +0200 |
commit | 1a99077d1cfa1d66b984fec9b956ed8fcd8c4cff (patch) | |
tree | 69390c00fe8cdebc05d450be423971ebbbe35240 /src/common/grfio.c | |
parent | 3a19ceb903629a9ff7ce85f800c1b4fefc8aa2c5 (diff) | |
download | hercules-1a99077d1cfa1d66b984fec9b956ed8fcd8c4cff.tar.gz hercules-1a99077d1cfa1d66b984fec9b956ed8fcd8c4cff.tar.bz2 hercules-1a99077d1cfa1d66b984fec9b956ed8fcd8c4cff.tar.xz hercules-1a99077d1cfa1d66b984fec9b956ed8fcd8c4cff.zip |
Various changes to the des interface
Mostly stylistic changes. Cleaned up documentation.
Signed-off-by: Haru <haru@dotalux.com>
Diffstat (limited to 'src/common/grfio.c')
-rw-r--r-- | src/common/grfio.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/common/grfio.c b/src/common/grfio.c index c5c38455d..7f860acc6 100644 --- a/src/common/grfio.c +++ b/src/common/grfio.c @@ -121,9 +121,9 @@ static uint8_t grf_substitution(uint8_t in) } #if 0 /* this is not used anywhere, is it ok to delete? */ -static void grf_shuffle_enc(struct BIT64 *src) +static void grf_shuffle_enc(struct des_bit64 *src) { - struct BIT64 out; + struct des_bit64 out; out.b[0] = src->b[3]; out.b[1] = src->b[4]; @@ -138,9 +138,9 @@ static void grf_shuffle_enc(struct BIT64 *src) } #endif // 0 -static void grf_shuffle_dec(struct BIT64 *src) +static void grf_shuffle_dec(struct des_bit64 *src) { - struct BIT64 out; + struct des_bit64 out; out.b[0] = src->b[3]; out.b[1] = src->b[4]; @@ -156,8 +156,8 @@ static void grf_shuffle_dec(struct BIT64 *src) static void grf_decode_header(unsigned char* buf, size_t len) { - struct BIT64 *p = (struct BIT64 *)buf; - size_t nblocks = len / sizeof(struct BIT64); + struct des_bit64 *p = (struct des_bit64 *)buf; + size_t nblocks = len / sizeof(struct des_bit64); size_t i; // first 20 blocks are all des-encrypted @@ -169,8 +169,8 @@ static void grf_decode_header(unsigned char* buf, size_t len) static void grf_decode_full(unsigned char* buf, size_t len, int cycle) { - struct BIT64 *p = (struct BIT64 *)buf; - size_t nblocks = len / sizeof(struct BIT64); + struct des_bit64 *p = (struct des_bit64 *)buf; + size_t nblocks = len / sizeof(struct des_bit64); int dcycle, scycle; size_t i, j; |