diff options
Diffstat (limited to 'sysdeps/unix')
-rw-r--r-- | sysdeps/unix/grantpt.c | 3 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/ifreq.h | 6 |
2 files changed, 8 insertions, 1 deletions
diff --git a/sysdeps/unix/grantpt.c b/sysdeps/unix/grantpt.c index 5f27ce91e3..98d601cf67 100644 --- a/sysdeps/unix/grantpt.c +++ b/sysdeps/unix/grantpt.c @@ -55,7 +55,8 @@ pts_name (int fd, char **pts, size_t buf_len) /* ptsname_r returns with ENOTTY to indicate a descriptor not referring to a pty master. For this condition, grantpt must return EINVAL. */ - errno = EINVAL; + rv = EINVAL; + errno = rv; /* Not necessarily set by __ptsname_r. */ break; } diff --git a/sysdeps/unix/sysv/linux/ifreq.h b/sysdeps/unix/sysv/linux/ifreq.h index 9d42664444..f498e5c32a 100644 --- a/sysdeps/unix/sysv/linux/ifreq.h +++ b/sysdeps/unix/sysv/linux/ifreq.h @@ -105,6 +105,12 @@ __ifreq (struct ifreq **ifreqs, int *num_ifs, int sockfd) *ifreqs = realloc (ifc.ifc_buf, nifs * sizeof (struct ifreq)); } +static inline struct ifreq * +__if_nextreq (struct ifreq *ifr) +{ + return ifr + 1; +} + static inline void __if_freereq (struct ifreq *ifreqs, int num_ifs) { |