projects
/
bertos.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Restore pipefail.
[bertos.git]
/
bertos
/
sec
/
hash
/
sha1.h
diff --git
a/bertos/sec/hash/sha1.h
b/bertos/sec/hash/sha1.h
index 734779ab3e048524b62a86cd72b5b9762b7aefe3..eff7fa70df8fb9da8e95efb93c13c181a369306c 100644
(file)
--- a/
bertos/sec/hash/sha1.h
+++ b/
bertos/sec/hash/sha1.h
@@
-41,6
+41,7
@@
#include <cfg/compiler.h>
#include <sec/hash.h>
#include <cfg/compiler.h>
#include <sec/hash.h>
+#include <alloca.h>
/**
* Context for SHA1 computation.
/**
* Context for SHA1 computation.
@@
-54,6
+55,9
@@
typedef struct {
void SHA1_init(SHA1_Context *context);
void SHA1_init(SHA1_Context *context);
+#define SHA1_stackinit(...) \
+ ({ SHA1_Context *ctx = alloca(sizeof(SHA1_Context)); SHA1_init(ctx, ##__VA_ARGS__); &ctx->h; })
+
int SHA1_testSetup(void);
int SHA1_testRun(void);
int SHA1_testTearDown(void);
int SHA1_testSetup(void);
int SHA1_testRun(void);
int SHA1_testTearDown(void);