aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGlyph <glyph@twistedmatrix.com>2015-06-26 23:17:06 -0700
committerGlyph <glyph@twistedmatrix.com>2015-06-26 23:17:06 -0700
commitadd79c02c102f2874974bdec727c9733a48685cc (patch)
treeab44330e94929568d8e1b3a5d63cae1e23c50037 /src
parent79b291dcf6a263698d921b534d34bf63b5febfcf (diff)
downloadcryptography-add79c02c102f2874974bdec727c9733a48685cc.tar.gz
cryptography-add79c02c102f2874974bdec727c9733a48685cc.tar.bz2
cryptography-add79c02c102f2874974bdec727c9733a48685cc.zip
comply with C coding standard, for which there is no linter
Diffstat (limited to 'src')
-rw-r--r--src/_cffi_src/openssl/engine.py14
-rw-r--r--src/cryptography/hazmat/bindings/openssl/binding.py4
2 files changed, 9 insertions, 9 deletions
diff --git a/src/_cffi_src/openssl/engine.py b/src/_cffi_src/openssl/engine.py
index bc5c1906..821c9235 100644
--- a/src/_cffi_src/openssl/engine.py
+++ b/src/_cffi_src/openssl/engine.py
@@ -12,12 +12,12 @@ TYPES = """
static const long Cryptography_HAS_ENGINE_CRYPTODEV;
struct rand_meth_st {
- void (*seed)(const void *buf, int num);
- int (*bytes)(unsigned char *buf, int num);
- void (*cleanup)(void);
- void (*add)(const void *buf, int num, double entropy);
- int (*pseudorand)(unsigned char *buf, int num);
- int (*status)(void);
+ void (*seed)(const void *, int);
+ int (*bytes)(unsigned char *, int);
+ void (*cleanup)();
+ void (*add)(const void *, int, double);
+ int (*pseudorand)(unsigned char *, int);
+ int (*status)();
};
typedef ... ENGINE;
@@ -28,7 +28,7 @@ typedef ... ECDSA_METHOD;
typedef ... DH_METHOD;
typedef struct rand_meth_st RAND_METHOD;
typedef ... STORE_METHOD;
-typedef int(*ENGINE_GEN_INT_FUNC_PTR)(ENGINE*);
+typedef int (*ENGINE_GEN_INT_FUNC_PTR)(ENGINE *);
typedef ... *ENGINE_CTRL_FUNC_PTR;
typedef ... *ENGINE_LOAD_KEY_PTR;
typedef ... *ENGINE_CIPHERS_PTR;
diff --git a/src/cryptography/hazmat/bindings/openssl/binding.py b/src/cryptography/hazmat/bindings/openssl/binding.py
index 35ea4979..f85429d8 100644
--- a/src/cryptography/hazmat/bindings/openssl/binding.py
+++ b/src/cryptography/hazmat/bindings/openssl/binding.py
@@ -53,7 +53,7 @@ class Binding(object):
method.seed = cls.ffi.NULL
@retain
- @cls.ffi.callback("int (*)(unsigned char *buf, int num)", error=0)
+ @cls.ffi.callback("int (*)(unsigned char *, int)", error=0)
def osrandom_rand_bytes(buf, size):
signed = cls.ffi.cast("char*", buf)
result = os.urandom(size)
@@ -61,7 +61,7 @@ class Binding(object):
return 1
@retain
- @cls.ffi.callback("int (*)(unsigned char *buf, int num)", error=0)
+ @cls.ffi.callback("int (*)(unsigned char *, int)", error=0)
def osrandom_pseudo_rand_bytes(buf, size):
result = osrandom_rand_bytes(buf, size)
if result == 0: