From ff63f9a47bb5a47aa5dc9e0ea20e93be1ee17c6f Mon Sep 17 00:00:00 2001 From: midipix Date: Mon, 26 Dec 2016 08:26:19 +0000 Subject: ptyc_pty_own(): properly convert the message's uintptr_t members to pid_t size. --- src/internal/ptycon_ioctl_impl.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/internal/ptycon_ioctl_impl.h b/src/internal/ptycon_ioctl_impl.h index d87ff3a..6c18e49 100644 --- a/src/internal/ptycon_ioctl_impl.h +++ b/src/internal/ptycon_ioctl_impl.h @@ -84,7 +84,7 @@ static int32_t ptyc_pty_own( return status; /* simulated fork */ - sessioninfo.pid = rtdata->cid_self.process_id; + sessioninfo.pid = (int32_t)rtdata->cid_self.process_id; sessioninfo.pgid = sessioninfo.pgid ? sessioninfo.pgid : -1; sessioninfo.sid = 0; sessioninfo.syspid = 0; @@ -95,9 +95,9 @@ static int32_t ptyc_pty_own( return status; /* setsid() */ - sessioninfo.pid = rtdata->cid_self.process_id; - sessioninfo.pgid = rtdata->cid_self.process_id; - sessioninfo.sid = rtdata->cid_self.process_id; + sessioninfo.pid = (int32_t)rtdata->cid_self.process_id; + sessioninfo.pgid = (int32_t)rtdata->cid_self.process_id; + sessioninfo.sid = (int32_t)rtdata->cid_self.process_id; sessioninfo.syspid = 0; if ((status = ntapi->tty_client_session_set( -- cgit v1.2.3