Introduced wrapper macros snew(), snewn() and sresize() for the
[u/mdw/putty] / sshsha.c
index d8fc569..d7c1f43 100644 (file)
--- a/sshsha.c
+++ b/sshsha.c
@@ -195,7 +195,7 @@ void SHA_Simple(void *p, int len, unsigned char *output)
 
 static void *sha1_make_context(void)
 {
-    return smalloc(2*sizeof(SHA_State));
+    return snewn(2, SHA_State);
 }
 
 static void sha1_free_context(void *handle)