diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2013-04-11 10:08:05 +0200 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2013-04-11 10:08:05 +0200 |
commit | 7ab02dce5c60453c454dd8645a63a5ef33f6a546 (patch) | |
tree | 564fe31b905223c1abc7801c982edadb53fa96b6 | |
parent | 078b010af6317ad325a9f10a901f8a279c8d0899 (diff) | |
download | rsyslog-7ab02dce5c60453c454dd8645a63a5ef33f6a546.tar.gz rsyslog-7ab02dce5c60453c454dd8645a63a5ef33f6a546.tar.bz2 rsyslog-7ab02dce5c60453c454dd8645a63a5ef33f6a546.zip |
cleanup
-rw-r--r-- | runtime/libgcry.c | 40 |
1 files changed, 0 insertions, 40 deletions
diff --git a/runtime/libgcry.c b/runtime/libgcry.c index c1ab3abf..af70e581 100644 --- a/runtime/libgcry.c +++ b/runtime/libgcry.c @@ -199,43 +199,3 @@ rsgcryExit(void) { return; } - -#if 0 // we use this for the tool, only! -static void -doDeCrypt(FILE *fpin, FILE *fpout) -{ - gcry_error_t gcryError; - char buf[64*1024]; - size_t nRead, nWritten; - size_t nPad; - - while(1) { - nRead = fread(buf, 1, sizeof(buf), fpin); - if(nRead == 0) - break; - nPad = (blkLength - nRead % blkLength) % blkLength; - fprintf(stderr, "read %d chars, blkLength %d, mod %d, pad %d\n", nRead, blkLength, - nRead % blkLength, nPad); - gcryError = gcry_cipher_decrypt( - gcryCipherHd, // gcry_cipher_hd_t - buf, // void * - nRead, // size_t - NULL, // const void * - 0); // size_t - if (gcryError) { - fprintf(stderr, "gcry_cipher_encrypt failed: %s/%s\n", - gcry_strsource(gcryError), - gcry_strerror(gcryError)); - return; - } -fprintf(stderr, "in remove pad, %d\n", nRead); - removePadding(buf, &nRead); -fprintf(stderr, "out remove pad %d\n", nRead); - nWritten = fwrite(buf, 1, nRead, fpout); - if(nWritten != nRead) { - perror("fpout"); - return; - } - } -} -#endif |