src/os/linux/vm/attachListener_linux.cpp

changeset 5264
e95fc50106cf
parent 2314
f95d63e2154a
child 5412
2e8f19c2feef
     1.1 --- a/src/os/linux/vm/attachListener_linux.cpp	Thu Jun 13 11:16:38 2013 -0700
     1.2 +++ b/src/os/linux/vm/attachListener_linux.cpp	Fri Jun 14 07:46:22 2013 -0700
     1.3 @@ -199,7 +199,7 @@
     1.4    ::unlink(initial_path);
     1.5    int res = ::bind(listener, (struct sockaddr*)&addr, sizeof(addr));
     1.6    if (res == -1) {
     1.7 -    RESTARTABLE(::close(listener), res);
     1.8 +    ::close(listener);
     1.9      return -1;
    1.10    }
    1.11  
    1.12 @@ -212,7 +212,7 @@
    1.13        }
    1.14    }
    1.15    if (res == -1) {
    1.16 -    RESTARTABLE(::close(listener), res);
    1.17 +    ::close(listener);
    1.18      ::unlink(initial_path);
    1.19      return -1;
    1.20    }
    1.21 @@ -340,24 +340,21 @@
    1.22      struct ucred cred_info;
    1.23      socklen_t optlen = sizeof(cred_info);
    1.24      if (::getsockopt(s, SOL_SOCKET, SO_PEERCRED, (void*)&cred_info, &optlen) == -1) {
    1.25 -      int res;
    1.26 -      RESTARTABLE(::close(s), res);
    1.27 +      ::close(s);
    1.28        continue;
    1.29      }
    1.30      uid_t euid = geteuid();
    1.31      gid_t egid = getegid();
    1.32  
    1.33      if (cred_info.uid != euid || cred_info.gid != egid) {
    1.34 -      int res;
    1.35 -      RESTARTABLE(::close(s), res);
    1.36 +      ::close(s);
    1.37        continue;
    1.38      }
    1.39  
    1.40      // peer credential look okay so we read the request
    1.41      LinuxAttachOperation* op = read_request(s);
    1.42      if (op == NULL) {
    1.43 -      int res;
    1.44 -      RESTARTABLE(::close(s), res);
    1.45 +      ::close(s);
    1.46        continue;
    1.47      } else {
    1.48        return op;
    1.49 @@ -408,7 +405,7 @@
    1.50    }
    1.51  
    1.52    // done
    1.53 -  RESTARTABLE(::close(this->socket()), rc);
    1.54 +  ::close(this->socket());
    1.55  
    1.56    // were we externally suspended while we were waiting?
    1.57    thread->check_and_wait_while_suspended();

mercurial