remove dead code caught by Coverity

This commit is contained in:
Michael Rash 2013-05-07 23:02:49 -04:00
parent 50f0ee2f7d
commit 8d980ae686
3 changed files with 3 additions and 8 deletions

View File

@ -447,7 +447,7 @@ main(int argc, char **argv)
*/
if(options.digest_type)
{
fko_set_spa_digest_type(ctx, options.digest_type);
res = fko_set_spa_digest_type(ctx, options.digest_type);
if(res != FKO_SUCCESS)
{
errmsg("fko_set_spa_digest_type", res);

View File

@ -213,14 +213,12 @@ rijndael_init(RIJNDAEL_context *ctx, const char *key,
if(encryption_mode == FKO_ENC_MODE_CBC
|| encryption_mode == FKO_ENC_MODE_CBC_LEGACY_IV)
ctx->mode = MODE_CBC;
else if(encryption_mode == FKO_ENC_MODE_CFB)
ctx->mode = MODE_CFB;
else if(encryption_mode == FKO_ENC_MODE_CTR)
ctx->mode = MODE_CTR;
else if(encryption_mode == FKO_ENC_MODE_PCBC)
ctx->mode = MODE_PCBC;
else if(encryption_mode == FKO_ENC_MODE_OFB)
ctx->mode = MODE_OFB;
else if(encryption_mode == FKO_ENC_MODE_CTR)
ctx->mode = MODE_CTR;
else if(encryption_mode == FKO_ENC_MODE_CFB)
ctx->mode = MODE_CFB;
else if(encryption_mode == FKO_ENC_MODE_ECB)

View File

@ -149,9 +149,6 @@ _run_extcmd(uid_t user_uid, const char *cmd, char *so_buf, const size_t so_buf_s
while((fgets(so_read_buf, IO_READ_BUF_LEN, ipt)) != NULL)
{
if(so_buf == NULL)
continue;
strlcat(so_buf, so_read_buf, so_buf_sz);
if(strlen(so_buf) >= so_buf_sz-1)