Commit git-
c38dbb9 inadvertently broke local MINIX3-on-MINIX3 builds,
since its libc changes relied on VFS being upgraded already as well.
As a result, after installing the new libc, networking ceased to work,
leading to curl(1) failing later on in the build process. This patch
introduces transitional code that is necessary for the build process
to complete, after which it is obsolete again.
Change-Id: I93bf29c01d228e3d7efc7b01befeff682954f54d
nwio_udpopt_t udpopt;
r = __accept(sock, address, address_len);
- if (r != -1 || errno != ENOTSOCK)
+ if (r != -1 || (errno != ENOTSOCK && errno != ENOSYS))
return r;
r= _tcp_accept(sock, address, address_len);
struct sockaddr_un uds_addr;
r = __bind(sock, address, address_len);
- if (r != -1 || errno != ENOTSOCK)
+ if (r != -1 || (errno != ENOTSOCK && errno != ENOSYS))
return r;
r= ioctl(sock, NWIOGTCPCONF, &tcpconf);
nwio_udpopt_t udpopt;
r = __connect(sock, address, address_len);
- if (r != -1 || errno != ENOTSOCK)
+ if (r != -1 || (errno != ENOTSOCK && errno != ENOSYS))
return r;
r= ioctl(sock, NWIOGTCPCONF, &tcpconf);
struct sockaddr_un uds_addr;
r = __getpeername(sock, address, address_len);
- if (r != -1 || errno != ENOTSOCK)
+ if (r != -1 || (errno != ENOTSOCK && errno != ENOSYS))
return r;
r= ioctl(sock, NWIOGTCPCONF, &tcpconf);
struct sockaddr_un uds_addr;
r = __getsockname(fd, address, address_len);
- if (r != -1 || errno != ENOTSOCK)
+ if (r != -1 || (errno != ENOTSOCK && errno != ENOSYS))
return r;
#if DEBUG
struct sockaddr_un uds_addr;
r = __getsockopt(sock, level, option_name, option_value, option_len);
- if (r != -1 || errno != ENOTSOCK)
+ if (r != -1 || (errno != ENOTSOCK && errno != ENOSYS))
return r;
r= ioctl(sock, NWIOGTCPOPT, &tcpopt);
int r;
r = __listen(sock, backlog);
- if (r != -1 || errno != ENOTSOCK)
+ if (r != -1 || (errno != ENOTSOCK && errno != ENOSYS))
return r;
r= ioctl(sock, NWIOTCPLISTENQ, &backlog);
int uds_sotype = -1;
r = __recvfrom(sock, buffer, length, flags, address, address_len);
- if (r != -1 || errno != ENOTSOCK)
+ if (r != -1 || (errno != ENOTSOCK && errno != ENOSYS))
return r;
#if DEBUG
int uds_sotype;
r = __recvmsg(sock, msg, flags);
- if (r != -1 || errno != ENOTSOCK)
+ if (r != -1 || (errno != ENOTSOCK && errno != ENOSYS))
return r;
if (msg == NULL) {
int uds_sotype;
r = __sendmsg(sock, msg, flags);
- if (r != -1 || errno != ENOTSOCK)
+ if (r != -1 || (errno != ENOTSOCK && errno != ENOSYS))
return r;
if (msg == NULL) {
int uds_sotype = -1;
r = __sendto(sock, message, length, flags, dest_addr, dest_len);
- if (r != -1 || errno != ENOTSOCK)
+ if (r != -1 || (errno != ENOTSOCK && errno != ENOSYS))
return r;
r= ioctl(sock, NWIOGTCPOPT, &tcpopt);
struct sockaddr_un uds_addr;
r = __setsockopt(sock, level, option_name, option_value, option_len);
- if (r != -1 || errno != ENOTSOCK)
+ if (r != -1 || (errno != ENOTSOCK && errno != ENOSYS))
return r;
r= ioctl(sock, NWIOGTCPOPT, &tcpopt);
nwio_tcpconf_t tcpconf;
r = __shutdown(sock, how);
- if (r != -1 || errno != ENOTSOCK)
+ if (r != -1 || (errno != ENOTSOCK && errno != ENOSYS))
return r;
r= ioctl(sock, NWIOGTCPCONF, &tcpconf);
int r, sock_type;
r = __socket(domain, type, protocol);
- if (r != -1 || errno != EAFNOSUPPORT)
+ if (r != -1 || (errno != EAFNOSUPPORT && errno != ENOSYS))
return r;
sock_type = type & ~SOCK_FLAGS_MASK;
int r;
r = __socketpair(domain, type, protocol, sv);
- if (r != -1 || errno != EAFNOSUPPORT)
+ if (r != -1 || (errno != EAFNOSUPPORT && errno != ENOSYS))
return r;
#if DEBUG