make sure error queue is totally emptied

PR: 359
This commit is contained in:
Nils Larsch 2005-04-07 22:53:35 +00:00
parent eb3eab20a8
commit f763e0b5ae
6 changed files with 6 additions and 6 deletions

View file

@ -197,7 +197,7 @@ static int asn1_d2i_read_bio(BIO *in, BUF_MEM **pb)
if (e != ASN1_R_TOO_LONG)
goto err;
else
ERR_get_error(); /* clear error */
ERR_clear_error(); /* clear error */
}
i=c.p-p;/* header length */
off+=i; /* end of data */

View file

@ -184,7 +184,7 @@ long CONF_get_number(LHASH *conf,const char *group,const char *name)
if (status == 0)
{
/* This function does not believe in errors... */
ERR_get_error();
ERR_clear_error();
}
return result;
}

View file

@ -254,7 +254,7 @@ static CONF_MODULE *module_load_dso(const CONF *cnf, char *name, char *value,
path = NCONF_get_string(cnf, value, "path");
if (!path)
{
ERR_get_error();
ERR_clear_error();
path = name;
}
dso = DSO_load(NULL, path, NULL, 0);

View file

@ -414,7 +414,7 @@ ASN1_OBJECT *OBJ_txt2obj(const char *s, int no_name)
i=a2d_ASN1_OBJECT(NULL,0,s,-1);
if (i <= 0) {
/* Clear the error */
ERR_get_error();
ERR_clear_error();
return NULL;
}
/* Work out total size */

View file

@ -204,7 +204,7 @@ int bio_ber_get_header(BIO *bio, BIO_BER_CTX *ctx)
if ((ctx->buf_len < BER_BUF_SIZE) &&
(ERR_GET_REASON(ERR_peek_error()) == ASN1_R_TOO_LONG))
{
ERR_get_error(); /* clear the error */
ERR_clear_error(); /* clear the error */
BIO_set_retry_read(b);
}
return(-1);

View file

@ -520,7 +520,7 @@ static int ssleay_rand_pseudo_bytes(unsigned char *buf, int num)
err = ERR_peek_error();
if (ERR_GET_LIB(err) == ERR_LIB_RAND &&
ERR_GET_REASON(err) == RAND_R_PRNG_NOT_SEEDED)
(void)ERR_get_error();
ERR_clear_error();
}
return (ret);
}