chore: use int64_t instead of long
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
f4463d803e
commit
92946eec91
|
@ -1,5 +1,6 @@
|
|||
#include <cmath>
|
||||
#include <cassert>
|
||||
#include <cstdint>
|
||||
#include <stdexcept>
|
||||
#include <tuple>
|
||||
#include "generator.h"
|
||||
|
@ -7,7 +8,7 @@
|
|||
using namespace std;
|
||||
|
||||
struct G_state{
|
||||
long k;
|
||||
int64_t k;
|
||||
unsigned __int128 ctr;
|
||||
};
|
||||
|
||||
|
@ -18,7 +19,7 @@ G_state *initialize_generator(){
|
|||
return G;
|
||||
};
|
||||
|
||||
string do_crypto(long k, unsigned __int128 ctr){
|
||||
string do_crypto(int64_t k, unsigned __int128 ctr){
|
||||
/* this function calls the block cipher
|
||||
* returns a string of k*(16 bytes);
|
||||
do whatever atm */
|
||||
|
|
|
@ -10,7 +10,7 @@ struct G_state;
|
|||
/* initializes generator */
|
||||
G_state *initialize_generator();
|
||||
|
||||
std::string do_crypto(long k, unsigned __int128 ctr);
|
||||
std::string do_crypto(int64_t k, unsigned __int128 ctr);
|
||||
|
||||
std::tuple<std::string, G_state> generate_blocks(G_state G, int k_blocks);
|
||||
|
||||
|
|
Reference in New Issue