diff options
| author | ame <[email protected]> | 2023-10-23 21:35:42 -0500 |
|---|---|---|
| committer | ame <[email protected]> | 2023-10-23 21:35:42 -0500 |
| commit | b40dc47dc4ae453674ec7b31f04aaf1b911010aa (patch) | |
| tree | 7678bca74fa6b9cf085a47a2b15993ea827cb6b8 /src/hash/sha01.c | |
| parent | bbdb94b7ed8acfb0ded338e4c2b92240e3f10128 (diff) | |
move md5 and fix memory leaks lol
Diffstat (limited to 'src/hash/sha01.c')
| -rw-r--r-- | src/hash/sha01.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/hash/sha01.c b/src/hash/sha01.c index e0cf1c7..b606daa 100644 --- a/src/hash/sha01.c +++ b/src/hash/sha01.c @@ -29,7 +29,7 @@ void i_sha01(unsigned version, char* out_stream, const char* input){ uint32_t hat = 0; for(int z = 0; z < tlen; z+=(512/8)){ uint32_t W[80]; - memset (W, 0, 80 * sizeof (uint32_t)); + memset(W, 0, 80 * sizeof (uint32_t)); for(int i = 0; i != 16; i++){ int t = 24; @@ -83,7 +83,7 @@ void i_sha01(unsigned version, char* out_stream, const char* input){ } sprintf(out_stream,"%02x%02x%02x%02x%02x",h0,h1,h2,h3,h4); - return; + free(by); } int l_sha1(lua_State* L){ |
