bankd_pcsc: Don't log every successful SCardTransmit

Contrary to other operations, SCardTransmit has a much higher frequency
and the logs should not be clobbered with "OK" lines all over the place.

Change-Id: Icf87b61d71722b2998ae78f9aee7c4ad94c46da7
This commit is contained in:
Harald Welte 2021-12-08 15:33:12 +01:00
parent 9f7ca61bb5
commit 50a0972a87
1 changed files with 3 additions and 2 deletions

View File

@ -297,9 +297,10 @@ static int pcsc_transceive(struct bankd_worker *worker, const uint8_t *out, size
long rc;
rc = SCardTransmit(worker->reader.pcsc.hCard, pioSendPci, out, out_len, &pioRecvPci, in, in_len);
PCSC_ERROR(worker, rc, "SCardTransmit");
/* don't use PCSC_ERROR here as we don't want to log every successful SCardTransmit */
if (rc != SCARD_S_SUCCESS)
LOGW_PCSC_ERROR(worker, rc, "SCardTransmit");
end:
return rc;
}