diff options
Diffstat (limited to 'src/libstrongswan/library.c')
-rw-r--r-- | src/libstrongswan/library.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/libstrongswan/library.c b/src/libstrongswan/library.c index ce3f827fa..3a76a5a05 100644 --- a/src/libstrongswan/library.c +++ b/src/libstrongswan/library.c @@ -43,6 +43,7 @@ ENUM(status_names, SUCCESS, DESTROY_ME, "VERIFY_ERROR", "INVALID_STATE", "DESTROY_ME", + "NEED_MORE", ); /** @@ -59,6 +60,18 @@ void *clalloc(void * pointer, size_t size) } /** + * Described in header. + */ +void memxor(u_int8_t dest[], u_int8_t src[], size_t n) +{ + size_t i; + for (i = 0; i < n; i++) + { + dest[i] ^= src[i]; + } +} + +/** * We use a single mutex for all refcount variables. This * is not optimal for performance, but the critical section * is not that long... |