Fix build on cygwin in strict mode (#1605)
This commit is contained in:
parent
be33e82b75
commit
04ef9dbf3b
@ -2459,7 +2459,7 @@ pgp_calculate_and_store_fingerprint(sc_card_t *card, time_t ctime,
|
||||
}
|
||||
else
|
||||
LOG_FUNC_RETURN(card->ctx, SC_ERROR_NOT_SUPPORTED);
|
||||
sc_log(card->ctx, "pk_packet_len is %lu", pk_packet_len);
|
||||
sc_log(card->ctx, "pk_packet_len is %"SC_FORMAT_LEN_SIZE_T"u", pk_packet_len);
|
||||
|
||||
fp_buffer_len = 3 + pk_packet_len;
|
||||
p = fp_buffer = calloc(fp_buffer_len, 1);
|
||||
|
@ -726,7 +726,7 @@ static int pcsc_cancel(sc_context_t *ctx)
|
||||
return SC_ERROR_NOT_ALLOWED;
|
||||
|
||||
#ifndef _WIN32
|
||||
if (gpriv->pcsc_wait_ctx != -1) {
|
||||
if (gpriv->pcsc_wait_ctx != (SCARDCONTEXT)-1) {
|
||||
rv = gpriv->SCardCancel(gpriv->pcsc_wait_ctx);
|
||||
if (rv == SCARD_S_SUCCESS) {
|
||||
/* Also close and clear the waiting context */
|
||||
@ -1509,7 +1509,7 @@ static int pcsc_wait_for_event(sc_context_t *ctx, unsigned int event_mask, sc_re
|
||||
}
|
||||
#ifndef _WIN32
|
||||
/* Establish a new context, assuming that it is called from a different thread with pcsc-lite */
|
||||
if (gpriv->pcsc_wait_ctx == -1) {
|
||||
if (gpriv->pcsc_wait_ctx == (SCARDCONTEXT)-1) {
|
||||
rv = gpriv->SCardEstablishContext(SCARD_SCOPE_USER, NULL, NULL, &gpriv->pcsc_wait_ctx);
|
||||
if (rv != SCARD_S_SUCCESS) {
|
||||
PCSC_LOG(ctx, "SCardEstablishContext(wait) failed", rv);
|
||||
|
Loading…
Reference in New Issue
Block a user