Merge pull request #3478 from brauner/2020-07-05/fixes

openpty: fix faulty rename
This commit is contained in:
Stéphane Graber 2020-07-05 21:14:22 -04:00 committed by GitHub
commit 6d3b68510a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -32,9 +32,9 @@
#include <sys/types.h>
#include <sys/ioctl.h>
#define _PATH_DEVPTMX "/dev/ptx"
#define _PATH_DEVPTMX "/dev/ptmx"
int openpty (int *aptx, int *apts, char *name, struct termios *termp,
int openpty (int *aptx, int *apty, char *name, struct termios *termp,
struct winsize *winp)
{
char buf[PATH_MAX];
@ -64,7 +64,7 @@ int openpty (int *aptx, int *apts, char *name, struct termios *termp,
ioctl(pty, TIOCSWINSZ, winp);
*aptx = ptx;
*apts = pty;
*apty = pty;
if (name != NULL)
strcpy(name, buf);