Fixing warnings under GCC4 in preparation to enable -Werror there as well:
* Replaced the use of offsetof() for structs that aren't PODs. Add a offset_of_member() macro to util/khash.h because that's what it's used for in our cases. * Change the signature of add_debugger_command()/remove_debugger_command() on GCC > 2 to avoid the depricated conversion from string constants to char *. * Adding some "suggested" parenthesis. I know that not everyone likes that, but it pointed out at least one bug that is fixed here as well. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29113 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -564,7 +564,7 @@ common_poll(struct pollfd *fds, nfds_t numFDs, bigtime_t timeout, bool kernel)
|
||||
int fd = fds[i].fd;
|
||||
|
||||
// initialize events masks
|
||||
sync->set[i].selected_events = fds[i].events & ~POLLNVAL
|
||||
sync->set[i].selected_events = (fds[i].events & ~POLLNVAL)
|
||||
| POLLERR | POLLHUP;
|
||||
sync->set[i].events = 0;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user