ws2_32: Add support for FROM_PROTOCOL_INFO to WSASocket()

Dmitry Timoshkov dmitry at
Mon May 26 02:40:07 CDT 2008

"Kai Blin" <kai.blin at> wrote:

> The C grammar printed in my edition of K&R says the following about 
> initializers
> initializer:
>  assignment-expression
>  { initializer-list }
>  { initializer-list , }
> so it looks like it's in the C standard that both are perfectly valid. I used 
> the perfectly valid form the rest of the file uses.

It's valid, and it's useful to avoid explicit structure members initializers, but
in the case of array initializers (which is the case) IMO it looks like a typo.

> > > The function is a mess with brace style and indentation. I've used the
> > > same indentaion as the if right above this one. The function wildly mixes
> > > two-space, three-space and four-space indents. In this case, I used
> > > two-space indents for the outer if and four-space indents for the inner
> > > ifs for better readability.
> >
> > Even if the overall style is a mess it's not a solution to add the code
> > which mixes 2 and 4 spaces indentation, and the code you have removed used
> > a consistent style.
> Ok. Fine. How about we finally agree on a coding standard, document that 
> somewhere and require all new patches to conform to that? Then at least one 
> wouldn't have to guess which broken indentation/braces to follow.

It's silly IMO to demand a coding standard when somebody pointed out to
an obviously sloppy code style on your side.

> > > PSDK has the AF_*, PF_*, SOCK_* and IPPROTO_* defines in winsock2.h as
> > > well, Wine hasn't. I preferred to keep them together.
> >
> > How much efforts would it take to put 1 line to a proper .h file?
> You're not even looking at what I wrote, are you? FROM_PROTOCOL_INFO is used 
> like an address family define, and I tried to keep all of them together.

All I say is that it's not OK to put the code at wrong place, even if there is
existing code which is at the wrong place already.


> So you don't care about this patch because you don't have a customer who needs 
> it,

I haven't said anything about customer needs, there is no need to speculate about it.

> I don't care about this patch because I can spend my free time on other 
> things. Let's just drop it then.

You already spent more time arguing than it would take to fix the patch, and


More information about the wine-devel mailing list