winscard: add pcsc-lite helpers for upcoming implementation

Mounir IDRASSI mounir.idrassi at idrix.fr
Thu May 24 00:02:55 CDT 2007


The code is definitely cleaner with all your suggestions. I'm applying
them now.

Mounir IDRASSI
IDRIX - Cryptography and IT Security Experts
http://www.idrix.fr


> James wrote:
>> This would be a lot cleaner as:
>>
>> if (!(liteSCardEstablishContext = (SCardEstablishContextPtr)
>> wine_dlsym(g_pcscliteHandle,"SCardEstablishContext",szErr,sizeof(szErr)))
>> {
>>    ERR("Failed to get SCardEstablishContext from pcsclite library. Error
>> = %s\n",szErr);
>>    goto error;
>> }
>
> I think in C you can skip the cast from void *, can't you?  e.g.
>
> liteSCardEstablishContext =
> wine_dlsym(g_pcscliteHandle,"SCardEstablishContext",szErr,sizeof(szErr));





More information about the wine-devel mailing list