include: add msasn1.h

Austin English austinenglish at gmail.com
Thu Feb 5 16:01:48 CST 2015


On Thu, Feb 5, 2015 at 3:55 PM, Charles Davis <cdavis5x at gmail.com> wrote:

>
> On Feb 5, 2015, at 1:46 PM, Austin English <austinenglish at gmail.com>
> wrote:
>
> On Thu, Feb 5, 2015 at 2:40 PM, Charles Davis <cdavis5x at gmail.com> wrote:
>
>>
>> > On Feb 5, 2015, at 1:20 PM, Austin English <austinenglish at gmail.com>
>> wrote:
>> > +typedef unsigned long ASN1uint32_t;
>> > +typedef signed long ASN1int32_t;
>> This won’t do what you (apparently) expect on 64-bit. At the very least,
>> you should use ULONG/DWORD and LONG here.
>>
>> > +#ifndef WINAPI
>> > +#define WINAPI __stdcall
>> > +#endif
>> This is most certainly wrong for Wine. I think you should include
>> “windef.h” if you need WINAPI.
>>
>
> The same definition is made in include/bcrypt.h (I considered removing it,
> then saw that it was already in bcrypt.h).
>
> Well I’ll be darned.
>
> I realized right after I replied to you that we define __stdcall to a
> macro anyway, so I guess this is OK.
>
>

I don't mind changing it, as you pointed out, it's probably not needed.


>
> I’m beginning to wonder if you copied this header (as well as <hidpi.h>)
> directly from Microsoft’s SDKs. You’ve been around long enough to know that
> that’s a big no-no around here.
>
>
> No, mingw:
>
> https://github.com/Alexpux/mingw-w64/blob/master/mingw-w64-headers/include/msasn1.h
>
> https://gitorious.org/mingw/mingw-w32api/source/4c8646e262e08f79e290f5211ab9e7386a85c753:include/ddk/hidpi.h
>
> I’m sorry for taking such an accusatory tone. It’s just that, the use of
> IN/OUT qualifiers (in <hidpi.h>) and Hungarian notation (here) made me
> suspicious. I guess if I have a beef with anyone, it’s MinGW ;).
>

No worries, I wanted to minimize the overall changes between the two
versions, aside from fixed indentation and removing mingw specific comments.

-- 
-Austin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.winehq.org/pipermail/wine-devel/attachments/20150205/4dcdf067/attachment-0001.html>


More information about the wine-devel mailing list