Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(19)

Issue 229863002: [NaCl SDK] nacl_io: Fix select() implementation so it doesn't assume entire fs_sets. (Closed)

Created:
6 years, 8 months ago by Sam Clegg
Modified:
6 years, 8 months ago
Reviewers:
binji
CC:
chromium-reviews
Visibility:
Public.

Description

[NaCl SDK] nacl_io: Fix select() implementation so it doesn't assume entire fd_sets. Turns out the application code (specifically openssh does this) is allows to pass incomplete fd_set structs as long as they can store at least nfds worth of information. This means that we can't call FD_ZERO on the pointers given to use since FD_ZERO assumes a full fd_set. This fixed a long standing memory corruption issue with openssh. R=binji@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=262849

Patch Set 1 #

Patch Set 2 : #

Total comments: 2

Patch Set 3 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+44 lines, -17 lines) Patch
M native_client_sdk/src/libraries/nacl_io/kernel_proxy.cc View 2 chunks +9 lines, -17 lines 0 comments Download
M native_client_sdk/src/tests/nacl_io_test/event_test.cc View 1 2 1 chunk +35 lines, -0 lines 0 comments Download

Messages

Total messages: 7 (0 generated)
Sam Clegg
6 years, 8 months ago (2014-04-09 00:39:05 UTC) #1
binji
lgtm, though you should add a test for this behavior.
6 years, 8 months ago (2014-04-09 00:47:45 UTC) #2
Sam Clegg
On 2014/04/09 00:47:45, binji wrote: > lgtm, though you should add a test for this ...
6 years, 8 months ago (2014-04-09 00:52:21 UTC) #3
binji
On 2014/04/09 00:52:21, Sam Clegg wrote: > On 2014/04/09 00:47:45, binji wrote: > > lgtm, ...
6 years, 8 months ago (2014-04-09 00:57:52 UTC) #4
Sam Clegg
Now with test!
6 years, 8 months ago (2014-04-09 21:03:11 UTC) #5
binji
slgtm https://codereview.chromium.org/229863002/diff/20001/native_client_sdk/src/tests/nacl_io_test/event_test.cc File native_client_sdk/src/tests/nacl_io_test/event_test.cc (right): https://codereview.chromium.org/229863002/diff/20001/native_client_sdk/src/tests/nacl_io_test/event_test.cc#newcode318 native_client_sdk/src/tests/nacl_io_test/event_test.cc:318: * We had an issue when select() was ...
6 years, 8 months ago (2014-04-09 21:26:21 UTC) #6
Sam Clegg
6 years, 8 months ago (2014-04-09 23:09:54 UTC) #7
Message was sent while issue was closed.
Committed patchset #3 manually as r262849 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698