Re: RSABASE/TESTS: Fix signed/unsigned comparison warnings

2004-08-09 Thread Dmitry Timoshkov
"Hans Leidekker" <[EMAIL PROTECTED]> wrote: > What do you propose then? I could do something like this: > > if (GetLastError()==(DWORD)NTE_BAD_KEYSET) > > But I consider a cast even uglier then introducing an intermediate > variable. We somehow have to live with the fact that NTE_BAD_KEYSET >

Re: RSABASE/TESTS: Fix signed/unsigned comparison warnings

2004-08-09 Thread Mike McCormack
Hans Leidekker wrote: where Wine defines STATUS_SUCCESS like so: #define STATUS_SUCCESS 0x which means STATUS_SUCCESS is handled by gcc as an unsigned value. This generates a warning because NTSTATUS is signed. If we look at the SDK definition we see something differen

Re: RSABASE/TESTS: Fix signed/unsigned comparison warnings

2004-08-09 Thread Hans Leidekker
On Monday 09 August 2004 12:17, Hans Leidekker wrote: > variable. We somehow have to live with the fact that NTE_BAD_KEYSET > is defined as ((HRESULT)0x80090016L), which is signed, and GetLastError() > returning DWORD, i.e unsigned. On a related note, I am looking at the last testsuite with signe

Re: RSABASE/TESTS: Fix signed/unsigned comparison warnings

2004-08-09 Thread Hans Leidekker
On Monday 09 August 2004 11:17, Dmitry Timoshkov wrote: > > - if (GetLastError()==NTE_BAD_KEYSET) > > + LONG gle = GetLastError(); > > + if (gle==NTE_BAD_KEYSET) > > This is ugly. This kind of "fixes" clutters Wine code and should be > deprecated. What do you propose then? I could do something l

Re: RSABASE/TESTS: Fix signed/unsigned comparison warnings

2004-08-09 Thread Dmitry Timoshkov
"Hans Leidekker" <[EMAIL PROTECTED]> wrote: > +static const int size_of_wchar = sizeof(WCHAR); > + ... > -ok(!memcmp(bufW, stringW, 5 * sizeof(WCHAR)), "bufW/stringW mismatch\n"); > +ok(!memcmp(bufW, stringW, 5 * size_of_wchar), "bufW/stringW mismatch\n"); > - if (GetLastError()==NTE_BAD