diff options
| author | Paul Eggert | 2011-10-27 11:15:18 -0700 |
|---|---|---|
| committer | Paul Eggert | 2011-10-27 11:15:18 -0700 |
| commit | dde1458174882077ca799d03f0adea91286650a3 (patch) | |
| tree | 92be2f956446908891691f74f11fa59b8e149f49 /src | |
| parent | 2121662f37c6e0ede0055a5e6dc74f65df832d3f (diff) | |
| download | emacs-dde1458174882077ca799d03f0adea91286650a3.tar.gz emacs-dde1458174882077ca799d03f0adea91286650a3.zip | |
* process.c: (emacs_get_tty_pgrp, Fprocess_running_child_p, process_send_signal):
Don't assume pid_t fits in int.
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 2 | ||||
| -rw-r--r-- | src/process.c | 8 |
2 files changed, 6 insertions, 4 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index f97195a9b2c..bdb3434558c 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -574,6 +574,8 @@ | |||
| 574 | (conv_lisp_to_sockaddr): Don't assume fixnums fit into int. | 574 | (conv_lisp_to_sockaddr): Don't assume fixnums fit into int. |
| 575 | (Faccept_process_output): Use duration_to_sec_usec to do proper | 575 | (Faccept_process_output): Use duration_to_sec_usec to do proper |
| 576 | overflow checking on durations. | 576 | overflow checking on durations. |
| 577 | (emacs_get_tty_pgrp, Fprocess_running_child_p, process_send_signal): | ||
| 578 | Don't assume pid_t fits in int. | ||
| 577 | * puresize.h (PURESIZE_RATIO): Shrink this to 8/6 on 32-bit hosts | 579 | * puresize.h (PURESIZE_RATIO): Shrink this to 8/6 on 32-bit hosts |
| 578 | configured --with-wide-int. | 580 | configured --with-wide-int. |
| 579 | * scroll.c (calculate_scrolling, calculate_direct_scrolling) | 581 | * scroll.c (calculate_scrolling, calculate_direct_scrolling) |
diff --git a/src/process.c b/src/process.c index 8270a57c177..f04f4611ab7 100644 --- a/src/process.c +++ b/src/process.c | |||
| @@ -5630,10 +5630,10 @@ Output from processes can arrive in between bunches. */) | |||
| 5630 | 5630 | ||
| 5631 | /* Return the foreground process group for the tty/pty that | 5631 | /* Return the foreground process group for the tty/pty that |
| 5632 | the process P uses. */ | 5632 | the process P uses. */ |
| 5633 | static int | 5633 | static pid_t |
| 5634 | emacs_get_tty_pgrp (struct Lisp_Process *p) | 5634 | emacs_get_tty_pgrp (struct Lisp_Process *p) |
| 5635 | { | 5635 | { |
| 5636 | int gid = -1; | 5636 | pid_t gid = -1; |
| 5637 | 5637 | ||
| 5638 | #ifdef TIOCGPGRP | 5638 | #ifdef TIOCGPGRP |
| 5639 | if (ioctl (p->infd, TIOCGPGRP, &gid) == -1 && ! NILP (p->tty_name)) | 5639 | if (ioctl (p->infd, TIOCGPGRP, &gid) == -1 && ! NILP (p->tty_name)) |
| @@ -5663,7 +5663,7 @@ return t unconditionally. */) | |||
| 5663 | { | 5663 | { |
| 5664 | /* Initialize in case ioctl doesn't exist or gives an error, | 5664 | /* Initialize in case ioctl doesn't exist or gives an error, |
| 5665 | in a way that will cause returning t. */ | 5665 | in a way that will cause returning t. */ |
| 5666 | int gid; | 5666 | pid_t gid; |
| 5667 | Lisp_Object proc; | 5667 | Lisp_Object proc; |
| 5668 | struct Lisp_Process *p; | 5668 | struct Lisp_Process *p; |
| 5669 | 5669 | ||
| @@ -5704,7 +5704,7 @@ process_send_signal (Lisp_Object process, int signo, Lisp_Object current_group, | |||
| 5704 | { | 5704 | { |
| 5705 | Lisp_Object proc; | 5705 | Lisp_Object proc; |
| 5706 | register struct Lisp_Process *p; | 5706 | register struct Lisp_Process *p; |
| 5707 | int gid; | 5707 | pid_t gid; |
| 5708 | int no_pgrp = 0; | 5708 | int no_pgrp = 0; |
| 5709 | 5709 | ||
| 5710 | proc = get_process (process); | 5710 | proc = get_process (process); |