[Bug 9425] Select behavior different on Wine

wine-bugs at winehq.org wine-bugs at winehq.org
Sun Feb 5 18:12:04 CST 2012


http://bugs.winehq.org/show_bug.cgi?id=9425

--- Comment #22 from Ruediger Meier <sweet_f_a at gmx.de> 2012-02-05 18:12:04 CST ---
(In reply to comment #21)
> Does it remove any of the TODOs from the socket test file? If not you have to
> add a new test there and prove it fixes this problem (it's usually the only way
> to get a code change in).

Just did it quick and dirty but I'll watch it over again this week. Also I
think get_poll_results() becomes quiet unreadable now so probably it should be
split into a 2 patches (refactoring and fix).


> You seen to be using k_w2e without initialization if no write FDs are set.
> Maybe there will be an overflow of the exceptfds array because of doubled fds,
> isn't it?

Thx, your point highlights my original comment 10. We must not even return from
WS_select() in case the user doesn't wait on exceptfds. But looking at
WS_select() there is now way to prevent this with fixing get_poll_results()
alone.
BTW would we even enter get_poll_results() if user only selects exceptfds?
Looks like we have to know about this move in WS_select() already.

> 
> General wine coding rules:
> Stick to the coding near the changes (see how { is used in the next line
> instead of in the end of the line)

Sry, I was happy to see you are not using GNU style but missed that it's not
100% kernel style;)

> Don't add {} if there is only one line in the if/else.

Hehe, I don't like this rule because if you would always add {} from the
beginning then any future additions will make the diff smaller (also it's
easier to add temporary debug lines) - accepeted anyway.

-- 
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
Do not reply to this email, post in Bugzilla using the
above URL to reply.
------- You are receiving this mail because: -------
You are watching all bug changes.



More information about the wine-bugs mailing list