Fix compiler warnings under Linux

This commit is contained in:
julien.pierre.bugs%sun.com 2005-02-24 00:22:59 +00:00
Родитель 2c3c71caa0
Коммит 8ac2cbecc8
2 изменённых файлов: 18 добавлений и 21 удалений

Просмотреть файл

@ -36,7 +36,7 @@
/* /*
* certi.h - private data structures for the certificate library * certi.h - private data structures for the certificate library
* *
* $Id: certi.h,v 1.13 2005/02/15 19:26:28 julien.pierre.bugs%sun.com Exp $ * $Id: certi.h,v 1.14 2005/02/24 00:22:59 julien.pierre.bugs%sun.com Exp $
*/ */
#ifndef _CERTI_H_ #ifndef _CERTI_H_
#define _CERTI_H_ #define _CERTI_H_
@ -125,16 +125,16 @@ struct CachedCrlStr {
}; };
/* constructor */ /* constructor */
SECStatus CachedCrl_Create(CachedCrl** returned, CERTSignedCrl* crl, static SECStatus CachedCrl_Create(CachedCrl** returned, CERTSignedCrl* crl,
CRLOrigin origin); CRLOrigin origin);
/* destructor */ /* destructor */
SECStatus CachedCrl_Destroy(CachedCrl* crl); static SECStatus CachedCrl_Destroy(CachedCrl* crl);
/* create hash table of CRL entries */ /* create hash table of CRL entries */
SECStatus CachedCrl_Populate(CachedCrl* crlobject); static SECStatus CachedCrl_Populate(CachedCrl* crlobject);
/* empty the cache content */ /* empty the cache content */
SECStatus CachedCrl_Depopulate(CachedCrl* crl); static SECStatus CachedCrl_Depopulate(CachedCrl* crl);
/* are these CRLs the same, as far as the cache is concerned ? /* are these CRLs the same, as far as the cache is concerned ?
Or are they the same token object, but with different DER ? */ Or are they the same token object, but with different DER ? */
@ -193,35 +193,35 @@ struct CRLDPCacheStr {
}; };
/* create a DPCache object */ /* create a DPCache object */
SECStatus DPCache_Create(CRLDPCache** returned, CERTCertificate* issuer, static SECStatus DPCache_Create(CRLDPCache** returned, CERTCertificate* issuer,
SECItem* subject, SECItem* dp); SECItem* subject, SECItem* dp);
/* destructor for CRL DPCache object */ /* destructor for CRL DPCache object */
SECStatus DPCache_Destroy(CRLDPCache* cache); static SECStatus DPCache_Destroy(CRLDPCache* cache);
/* add a new CRL object to the dynamic array of CRLs of the DPCache, and /* add a new CRL object to the dynamic array of CRLs of the DPCache, and
returns the cached CRL object . Needs write access to DPCache. */ returns the cached CRL object . Needs write access to DPCache. */
SECStatus DPCache_AddCRL(CRLDPCache* cache, CachedCrl* crl, PRBool* added); static SECStatus DPCache_AddCRL(CRLDPCache* cache, CachedCrl* crl, PRBool* added);
/* fetch the CRL for this DP from the PKCS#11 tokens */ /* fetch the CRL for this DP from the PKCS#11 tokens */
SECStatus DPCache_FetchFromTokens(CRLDPCache* cache, PRTime vfdate, void* wincx); static SECStatus DPCache_FetchFromTokens(CRLDPCache* cache, PRTime vfdate, void* wincx);
/* check if a particular SN is in the CRL cache and return its entry */ /* check if a particular SN is in the CRL cache and return its entry */
SECStatus DPCache_Lookup(CRLDPCache* cache, SECItem* sn, CERTCrlEntry** returned); static SECStatus DPCache_Lookup(CRLDPCache* cache, SECItem* sn, CERTCrlEntry** returned);
/* update the content of the CRL cache, including fetching of CRLs, and /* update the content of the CRL cache, including fetching of CRLs, and
reprocessing with specified issuer and date */ reprocessing with specified issuer and date */
SECStatus DPCache_GetUpToDate(CRLDPCache* cache, CERTCertificate* issuer, static SECStatus DPCache_GetUpToDate(CRLDPCache* cache, CERTCertificate* issuer,
PRBool readlocked, PRTime vfdate, void* wincx); PRBool readlocked, PRTime vfdate, void* wincx);
/* returns true if there are CRLs from PKCS#11 slots */ /* returns true if there are CRLs from PKCS#11 slots */
PRBool DPCache_HasTokenCRLs(CRLDPCache* cache); static PRBool DPCache_HasTokenCRLs(CRLDPCache* cache);
/* remove CRL at offset specified */ /* remove CRL at offset specified */
SECStatus DPCache_RemoveCRL(CRLDPCache* cache, PRUint32 offset); static SECStatus DPCache_RemoveCRL(CRLDPCache* cache, PRUint32 offset);
/* Pick best CRL to use . needs write access */ /* Pick best CRL to use . needs write access */
SECStatus DPCache_SelectCRL(CRLDPCache* cache); static SECStatus DPCache_SelectCRL(CRLDPCache* cache);
/* CRL issuer cache object /* CRL issuer cache object
This object tracks all the distribution point caches for a given issuer. This object tracks all the distribution point caches for a given issuer.
@ -245,7 +245,7 @@ struct CRLIssuerCacheStr {
}; };
/* create an issuer cache object (per CA subject ) */ /* create an issuer cache object (per CA subject ) */
SECStatus IssuerCache_Create(CRLIssuerCache** returned, static SECStatus IssuerCache_Create(CRLIssuerCache** returned,
CERTCertificate* issuer, CERTCertificate* issuer,
SECItem* subject, SECItem* dp); SECItem* subject, SECItem* dp);
@ -253,11 +253,11 @@ SECStatus IssuerCache_Create(CRLIssuerCache** returned,
SECStatus IssuerCache_Destroy(CRLIssuerCache* cache); SECStatus IssuerCache_Destroy(CRLIssuerCache* cache);
/* add a DPCache to the issuer cache */ /* add a DPCache to the issuer cache */
SECStatus IssuerCache_AddDP(CRLIssuerCache* cache, CERTCertificate* issuer, static SECStatus IssuerCache_AddDP(CRLIssuerCache* cache, CERTCertificate* issuer,
SECItem* subject, SECItem* dp, CRLDPCache** newdpc); SECItem* subject, SECItem* dp, CRLDPCache** newdpc);
/* get a particular DPCache object from an IssuerCache */ /* get a particular DPCache object from an IssuerCache */
CRLDPCache* IssuerCache_GetDPCache(CRLIssuerCache* cache, SECItem* dp); static CRLDPCache* IssuerCache_GetDPCache(CRLIssuerCache* cache, SECItem* dp);
/* CRL revocation cache object /* CRL revocation cache object

Просмотреть файл

@ -37,7 +37,7 @@
/* /*
* Moved from secpkcs7.c * Moved from secpkcs7.c
* *
* $Id: crl.c,v 1.43 2005/02/15 06:26:42 julien.pierre.bugs%sun.com Exp $ * $Id: crl.c,v 1.44 2005/02/24 00:22:59 julien.pierre.bugs%sun.com Exp $
*/ */
#include "cert.h" #include "cert.h"
@ -1869,7 +1869,6 @@ static int SortCRLsByThisUpdate(const void* arg1, const void* arg2)
PRTime timea, timeb; PRTime timea, timeb;
SECStatus rv = SECSuccess; SECStatus rv = SECSuccess;
CachedCrl* a, *b; CachedCrl* a, *b;
PRBool agood = PR_FALSE, bgood = PR_FALSE;
a = (CachedCrl*) arg1; a = (CachedCrl*) arg1;
b = (CachedCrl*) arg2; b = (CachedCrl*) arg2;
@ -1916,7 +1915,6 @@ static int SortCRLsByThisUpdate(const void* arg1, const void* arg2)
static int SortImperfectCRLs(const void* arg1, const void* arg2) static int SortImperfectCRLs(const void* arg1, const void* arg2)
{ {
CachedCrl* a, *b; CachedCrl* a, *b;
PRBool agood = PR_FALSE, bgood = PR_FALSE;
a = (CachedCrl*) arg1; a = (CachedCrl*) arg1;
b = (CachedCrl*) arg2; b = (CachedCrl*) arg2;
@ -2214,7 +2212,6 @@ static SECStatus CRLCache_GetIssuerCache(CRLCache* cache, SECItem* subject,
/* retrieve the full CRL object that best matches the content of a DPCache */ /* retrieve the full CRL object that best matches the content of a DPCache */
static CERTSignedCrl* GetBestCRL(CRLDPCache* cache, PRBool entries) static CERTSignedCrl* GetBestCRL(CRLDPCache* cache, PRBool entries)
{ {
PRInt32 i = 0;
CachedCrl* acrl = NULL; CachedCrl* acrl = NULL;
PORT_Assert(cache); PORT_Assert(cache);