Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nix
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 72462b4b6ec9
Choose a base ref
...
head repository: NixOS/nix
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 3162ad5ff497
Choose a head ref
  • 2 commits
  • 1 file changed
  • 2 contributors

Commits on Jul 18, 2017

  1. Do not try to fill fd_set with fd>=FD_SETSIZE

    This is UB and causes buffer overflow and crash on linux.
    veprbl committed Jul 18, 2017

    Verified

    This commit was signed with the committer’s verified signature. The key has expired.
    panzarino Zach Panzarino
    Copy the full SHA
    d5e1bff View commit details

Commits on Jul 19, 2017

  1. Merge pull request #1471 from veprbl/fdsetsize

    Do not try to fill fd_set with fd>=FD_SETSIZE
    edolstra authored Jul 19, 2017

    Verified

    This commit was signed with the committer’s verified signature. The key has expired.
    panzarino Zach Panzarino
    Copy the full SHA
    3162ad5 View commit details
Showing with 3 additions and 0 deletions.
  1. +3 −0 src/libstore/build.cc
3 changes: 3 additions & 0 deletions src/libstore/build.cc
Original file line number Diff line number Diff line change
@@ -3835,6 +3835,9 @@ void Worker::waitForInput()
int fdMax = 0;
for (auto & i : children) {
for (auto & j : i.fds) {
if (j >= FD_SETSIZE) {
throw BuildError("reached FD_SETSIZE limit");
}
FD_SET(j, &fds);
if (j >= fdMax) fdMax = j + 1;
}