bankd: Log more clearly if we fail to open a PC/SC reader
Related: SYS#5950 Change-Id: I424f585a8a37f21806898e59e350201119645a21
This commit is contained in:
parent
a04ff860c1
commit
7f8bce4f06
|
@ -237,13 +237,19 @@ static int pcsc_connect_slot_regex(struct bankd_worker *worker)
|
||||||
&dwActiveProtocol);
|
&dwActiveProtocol);
|
||||||
if (rc == SCARD_S_SUCCESS)
|
if (rc == SCARD_S_SUCCESS)
|
||||||
result = 0;
|
result = 0;
|
||||||
else
|
else {
|
||||||
LOGW_PCSC_ERROR(worker, rc, "SCardConnect");
|
LOGW_PCSC_ERROR(worker, rc, "SCardConnect");
|
||||||
|
goto out_readerfree;
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
p += strlen(p) + 1;
|
p += strlen(p) + 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (result < 0)
|
||||||
|
LOGW(worker, "Error: Cannot find PC/SC reader/slot matching using regex '%s'\n", worker->reader.name);
|
||||||
|
|
||||||
|
out_readerfree:
|
||||||
SCardFreeMemory(worker->reader.pcsc.hContext, mszReaders);
|
SCardFreeMemory(worker->reader.pcsc.hContext, mszReaders);
|
||||||
|
|
||||||
out_regfree:
|
out_regfree:
|
||||||
|
|
Loading…
Reference in New Issue