Re: ntdll: Store all 'comClass' attributes (try3)

2013-08-28 Thread Michael Stefaniuc
Hello Nikolay, On 08/27/2013 12:16 PM, Nikolay Sivov wrote: > +static OLEMISC get_olemisc_value(const WCHAR *str, int len) > +{ > +int min, max; > + > +min = 0; > +max = sizeof(olemisc_values)/sizeof(struct olemisc_entry) - 1; > + > +while (min <= max) > +{ > +int n, c;

Re: ntdll: Store all 'comClass' attributes (try2)

2013-08-27 Thread Alexandre Julliard
Nikolay Sivov writes: > +static OLEMISC get_olemisc_value(const WCHAR *str, int len) > +{ > +int min, max; > + > +min = 0; > +max = ARRAY_SIZE(olemisc_values) - 1; > + > +while (min <= max) > +{ > +int n, c; > + > +n = (min+max)/2; > + > +c = memcmp(ole

Re: ntdll: Store all 'comClass' attributes

2013-08-26 Thread Nikolay Sivov
On 8/26/2013 19:04, Alexandre Julliard wrote: Nikolay Sivov writes: +while (min <= max) +{ +int n, c; + +n = (min+max)/2; + +c = strncmpW(olemisc_values[n].name, str, len); strncmp isn't enough. Right, thanks.

Re: ntdll: Store all 'comClass' attributes

2013-08-26 Thread Alexandre Julliard
Nikolay Sivov writes: > +while (min <= max) > +{ > +int n, c; > + > +n = (min+max)/2; > + > +c = strncmpW(olemisc_values[n].name, str, len); strncmp isn't enough. -- Alexandre Julliard julli...@winehq.org