Mercurial > emacs
annotate src/process.h @ 98644:e1cc41b9282d
2008-10-12 Carsten Dominik <carsten.dominik@gmail.com>
* org.el (org-edit-fixed-width-region): Exclude final newline from
picture area.
* org-export-latex.el (org-export-latex-subcontent): Add labels to
sections, to make internal links work.
(org-export-latex-fontify-headline): Do not remove all text
properties, to make sure that target properties survive this
process.
* org-exp.el (org-export-preprocess-string): Change sequence of
modifications, to make sure links are prepared before the LaTeX
conversions do happen.
* org-attach.el (org-attach-delete-all): Renamed from
`org-attch-delete'. Add a security query before deleting the
entire directory. New optional argument FORCE can overrule the
security query.
(org-attach-delete-one): New command.
* org-attach.el (org-attach-file-list): Fix bug with directory.
* org.el (org-apps-regexp-alist): New function.
(org-file-apps): Add auto-mode to the default value.
(org-open-file): Use the new structure of org-file-apps.
* org-attach.el (org-attach): Support the new keys.
(org-attach-method): New option.
* org-bbdb.el (org-bbdb-anniversaries): Fix but with 29 Feb/1
March.
* org.el (org-remove-uniherited-tags): Fix reverse interpretation
of the list value o `org-use-tag-inheritance'.
* org-attach.el (org-attach-auto-tag): New option.
(org-attach-tag, org-attach-untag): New functions.
(org-attach-attach, org-attach-new, org-attach-sync): Call
`org-attach-tag'.
(org-attach-delete): Call `org-attach-untag'.
* org-attach.el: New file.
* org-table.el (orgtbl-self-insert-command): Make this work for
the keypad as well.
* org.el (org-add-log-setup): Limit searc for drawers to entry
text, not to subtree.
* org-clock.el (org-clock-heading-for-remember): New variable.
(org-clock-in): Set `org-clock-heading-for-remember'.
2008-10-12 James TD Smith <ahktenzero@mohorovi.cc>
* org-remember.el (org-remember-apply-template): Add new
expansions: %k, %K for currently clocked task and a link to the
currently clocked task, and %< to file notes in the currently
clocked task.
2008-10-12 Carsten Dominik <dominik@science.uva.nl>
* org-export-latex.el (org-export-latex-make-header): Also insert
the content of the property :latex-header-extra.
* org-exp.el (org-infile-export-plist): Put the content of
#+LATEX_HEADER: into the property :latex-header-extra.
* org-colview.el (org-columns-get-format-and-top-level): Remove
resetting the marker.
* org-colview-xemacs.el (org-columns-get-format-and-top-level):
Remove resetting the marker.
* org.el (org-entry-property-inherited-from): Improve docstring.
(org-entry-get-with-inheritance): Reset marker before starting the
search.
* org-exp.el (org-infile-export-plist): Allow multiple STYLE lines.
* org.el (org-entry-get-multivalued-property)
(org-entry-protect-space, org-entry-restore-space): New
functions.
(org-file-apps-defaults-macosx): Let postscript files be opened by
preview.
(org-time-stamp-inactive): Call `org-time-stamp'.
(org-time-stamp): New argument `inactive'. Also edit inacive
stamps. Convert time stamp type.
(org-open-file): Interpret the `default' value for the `command'
in `org-file-apps'.
* org-id.el (org-id-int-to-b36-one-digit)
(org-id-b36-to-int-one-digit, org-id-int-to-b36)
(org-id-b36-to-int, org-id-time-to-b36): Modified from b62 to
b36.
* org-id.el (org-id-reverse-string): New function.
(org-id-new): Use `org-id-reverse-string' to make sure the
beginning chars of the ID are mutating fast. This allows to use a
directory structure to spread things better.
(org-id-prefix): Changed default to nil.
* org-list.el (org-move-item-down, org-move-item-up): Remember and
restore the column of the cursor position.
* org-remember.el (org-remember-apply-template): Remove properties
from `initial'.
* org-wl.el (org-wl-open): Remove useless call to
`wl-thread-open-all'.
* org-remember.el (org-remember-handler): Fix bug with `bottom'
location.
* org-bbdb.el (org-bbdb-anniversaries): Require bbdb in
`org-bbdb-anniversaries'.
* org.el (org-get-next-sibling, org-forward-same-level): New
functions, similar to the outline versions, but invisible headings
are OK.
2008-10-12 Bastien Guerry <bzg@altern.org>
* org.el (org-auto-repeat-maybe): Insert a space between
the timestamp's type and the timestamp itself.
2008-10-12 Carsten Dominik <dominik@science.uva.nl>
* org-table.el (org-table-sum): Do not format the result with %g,
it does rounding when there are too many digits.
* org.el (org-map-entries): Protect the keyword-selecting variables.
2008-10-12 Bastien Guerry <bzg@altern.org>
* org-agenda.el (org-agenda-to-appt): Make sure the function check
against all agenda files.
2008-10-12 Carsten Dominik <dominik@science.uva.nl>
* org-list.el: New file, aggregating list functions from org.el
and org-export-latex.el.
* org.el (org-edit-src-region-extra): New option.
* org-agenda.el (org-agenda-to-appt): Fix bug with appointment
time before 1am.
2008-10-12 Bastien Guerry <bzg@altern.org>
* org-export-latex.el (org-export-latex-keywords-maybe): Bug fix.
2008-10-12 James TA Smith <ahktenzero@mohorovi.cc>
* org-plot.el (org-plot/gnuplot): Make tables starting with a
hline work correctly.
(org-plot/gnuplot-script): Put commas at the end of each script
line.
* org.el (org-get-refile-targets): Replace links with their
descriptions
(org-imenu-get-tree): Replace links with their descriptions.
* org-remember.el (org-remember-apply-template): Add a new
expansion for adding properties to remember items.
* org.el (org-add-log-setup): Skip over drawers (properties,
clocks etc) when adding notes.
* org-agenda.el (org-agenda-get-closed): show durations of clocked
items as well as the start and end times.
* org-compat.el (org-get-x-clipboard-compat): Add a compat
function for fetching the X clipboard on XEmacs and GNU Emacs 21.
* org-remember.el (org-get-x-clipboard): Use the compat
function to get clipboard values when x-selection-value is
unavailable. Use substring-no-properties instead of
set-text-properties to remove text properties from the clipboard
value.
* lisp/org-clock.el (org-update-mode-line): Support limiting the
modeline clock string, and display the full todo value in the
tooltip. Set a local keymap so mouse-3 on the clock string goes to
the currently clocked task.
(org-clock-string-limit): Add a custom value for the maximum
length of the clock string in the modeline.
(org-clock-mode-map): Add a keymap for the modeline string
2008-10-12 Carsten Dominik <dominik@science.uva.nl>
* org-compat.el (org-propertize): New function.
2008-10-12 Bastien Guerry <bzg@altern.org>
* org-export-latex.el (org-export-latex-tables): protect exported
tables from further special chars conversion.
(org-export-latex-preprocess): Preserve LaTeX environments.
(org-list-parse-list): Parse descriptive lists.
(org-list-to-generic, org-list-to-latex, org-list-to-html)
(org-list-to-texinfo): Export descriptive lists.
(org-quote-chars): Remove.
(org-export-latex-keywords-maybe): Use `replace-regexp-in-string'.
(org-export-latex-list-beginning-re): Rename to
`org-list-beginning-re'
(org-list-item-begin): Rename to `org-list-item-beginning'
2008-10-12 Carsten Dominik <dominik@science.uva.nl>
* org.el (org-refile): Allow refiling to the last entry in the
buffer.
(org-get-tags-at): Fix bug when inheritance is turned off.
* org.el (org-indent-line-function): No longer check for src
regions, this is too much overhead.
* org-agenda.el (org-agenda-highlight-todo): Fix bugs with keyword
matching.
* org.el (org-scan-tags): Make sure that tags matching is not case
sensitive. TODO keyword matching is case sensitive, however, to
avoid confusion with similar words that are not meant to be
keywords.
* org.el (org-get-local-tags-at): New function.
(org-get-local-tags): New function.
* org-exp.el (org-export-get-categories): New function.
* org-agenda.el (org-sorting-choice)
(org-agenda-sorting-strategy, org-agenda-get-todos)
(org-agenda-get-timestamps, org-agenda-get-deadlines)
(org-agenda-get-scheduled, org-agenda-get-blocks)
(org-entries-lessp): Implement sorting by TODO state.
(org-cmp-todo-state): New defsubst.
* org-colview.el (org-colview-construct-allowed-dates): New
function.
(org-columns-next-allowed-value): Use
`org-colview-construct-allowed-dates'.
* org-colview-xemacs.el (org-colview-construct-allowed-dates): New
function.
(org-columns-next-allowed-value): Use
`org-colview-construct-allowed-dates'.
* org.el (org-protect-slash): New function.
(org-get-refile-targets): Use `org-protect-slash'.
* org-agenda.el (org-global-tags-completion-table): New variable.
* org-exp.el (org-export-handle-export-tags): New function.
(org-export-preprocess-string): Call
`org-export-handle-export-tags'.
* org-plot.el: New file.
* org-publish.el (org-publish-expand-components): Function removed.
(org-publish-expand-projects): Allow components to have components.
* org.el (org-indent-line-function): Do not indent in regions that
are external source code.
(org-yank-and-fold-if-subtree): New function.
* org-agenda.el (org-agenda-todayp): New function.
(org-agenda-get-deadlines, org-agenda-get-scheduled): Use
`org-agenda-todayp'.
* org.el (org-insert-heading-respect-content)
(org-insert-todo-heading-respect-content): New commands.
(org-insert-heading-respect-content): New option.
(org-insert-heading): Respect `org-insert-heading-respect-content'.
* org-clock.el (org-clock-find-position): Make sure the note after
the clock line gets moved into the new clock drawer.
* org-id.el (org-id-new): New option.
* org-table.el (org-table-copy-down): Avoid overflow during
increment. Use prefix argument 0 to temporarily disable the
increment.
* org-exp.el (org-export-as-html): Do not turn on the major mode
if the buffer will be killed anyway.
(org-get-current-options): Exclude the #+TEXT field.
(org-export-as-html): Make sure text before the first headline is
a paragraph.
* org-publish.el (org-publish-org-to): Tell the exporter that this
buffer will be killed, so it is not necessary to do major mode
initialization.
* org-archive.el (org-archive-to-archive-sibling): Show empty
lines after folding the archive sibling.
* org.el (org-log-note-extra): New variable.
2008-10-12 Bastien Guerry <bzg@altern.org>
* org.el (org-additional-option-like-keywords): Added keywords for
the _QUOTE, _VERSE and _SRC environments.
* org-export-latex.el (org-export-latex-preprocess): Fix bug when
exporting _QUOTE and _VERSE environments.
2008-10-12 Carsten Dominik <dominik@science.uva.nl>
* org-agenda.el (org-agenda-filter-by-tag): New command.
* org-exp.el (org-get-current-options): Remove angular brackets
from the date entry.
* org.el (org-edit-fixed-width-region): New function.
(org-edit-fixed-width-region): Also try
`org-edit-fixed-width-region'.
(org-edit-fixed-width-region-mode): New option.
(org-activate-code): Only interprete lines starting with colon
plus a space as example lines.
* org-remember.el (org-remember-templates): Add nil instead of
empty strings to fix the length of remember templates.
* org-table.el (org-calc-default-modes): Fix the time format for
calc, from 12 hour to 24 hour clock.
* org-agenda.el (org-agenda-get-deadlines)
(org-agenda-get-scheduled): Avoid `time-of-day' extraction for
entries that are pre-warnings of deadlines or reminders.
* org.el (org-sort-entries-or-items): Make numeric and alpha
comparisons ignore any TODO keyword and priority cookie.
* org-remember.el (org-remember-handler): Reinterpretation of the
prefix argument.
* org-agenda.el (org-agenda-get-scheduled): Use new
`org-scheduled' face.
* org-faces.el (org-scheduled): New face.
* org-wl.el (org-wl-open): Remove incorrect declaration.
* org-gnus.el (org-gnus-store-link): Support for :to information
in gnus links.
* org-exp.el (org-export-as-html): Fixed typo in creator
information.
(org-export-protect-examples): New parameter indent. Insert extra
spaces only when this parameter is specified.
(org-export-preprocess-string): Call `org-export-protect-examples'
with an indentation parameter when exporting to ASCII.
* org-remember.el (org-remember-templates)
(org-remember-apply-template): Allow the file component to be a
function.
* org.el (org-goto-local-search-headings): Renamed from
`org-goto-local-search-forward-headings'. Added the possibility
to search backwards.
* org-export-latex.el (org-export-latex): New customization
group.
* org-agenda.el (org-write-agenda): Erase buffer for txt export.
* org-exp.el (org-html-do-expand): Allow {} to terminate
tex macro
* org.el (org-buffer-list): Select buffers based on major mode,
not on file name.
* org-agenda.el (org-agenda-align-tags): Fix bug with malformed
face property.
* org-colview.el (org-columns-display-here): Use
`org-columns-modify-value-for-display-function'.
* org-colview-xemacs.el (org-columns-display-here): Use
`org-columns-modify-value-for-display-function'.
* org.el (org-columns-modify-value-for-display-function): New option.
* org-publish.el (org-publish-file): Make sure the directory match
for the publishing directory works correctly.
* org-agenda.el (org-agenda-execute-calendar-command)
(org-agenda-diary-entry): Additional optional argument.
author | Carsten Dominik <dominik@science.uva.nl> |
---|---|
date | Sun, 12 Oct 2008 06:12:44 +0000 |
parents | d2c211c8ceda |
children | dcc7f5970d5c |
rev | line source |
---|---|
365 | 1 /* Definitions for asynchronous process control in GNU Emacs. |
75227
e90d04cd455a
Update copyright for years from Emacs 21 to present (mainly adding
Glenn Morris <rgm@gnu.org>
parents:
72726
diff
changeset
|
2 Copyright (C) 1985, 1994, 2001, 2002, 2003, 2004, |
79759 | 3 2005, 2006, 2007, 2008 Free Software Foundation, Inc. |
365 | 4 |
5 This file is part of GNU Emacs. | |
6 | |
94994
29adfc9354e7
Switch to recommended form of GPLv3 permissions notice.
Glenn Morris <rgm@gnu.org>
parents:
93201
diff
changeset
|
7 GNU Emacs is free software: you can redistribute it and/or modify |
365 | 8 it under the terms of the GNU General Public License as published by |
94994
29adfc9354e7
Switch to recommended form of GPLv3 permissions notice.
Glenn Morris <rgm@gnu.org>
parents:
93201
diff
changeset
|
9 the Free Software Foundation, either version 3 of the License, or |
29adfc9354e7
Switch to recommended form of GPLv3 permissions notice.
Glenn Morris <rgm@gnu.org>
parents:
93201
diff
changeset
|
10 (at your option) any later version. |
365 | 11 |
12 GNU Emacs is distributed in the hope that it will be useful, | |
13 but WITHOUT ANY WARRANTY; without even the implied warranty of | |
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
15 GNU General Public License for more details. | |
16 | |
17 You should have received a copy of the GNU General Public License | |
94994
29adfc9354e7
Switch to recommended form of GPLv3 permissions notice.
Glenn Morris <rgm@gnu.org>
parents:
93201
diff
changeset
|
18 along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ |
365 | 19 |
70209
7077caf6dc5a
Include headers for pid_t.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
69873
diff
changeset
|
20 #ifdef HAVE_SYS_TYPES_H |
7077caf6dc5a
Include headers for pid_t.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
69873
diff
changeset
|
21 #include <sys/types.h> |
7077caf6dc5a
Include headers for pid_t.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
69873
diff
changeset
|
22 #endif |
7077caf6dc5a
Include headers for pid_t.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
69873
diff
changeset
|
23 #ifdef HAVE_UNISTD_H |
7077caf6dc5a
Include headers for pid_t.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
69873
diff
changeset
|
24 #include <unistd.h> |
7077caf6dc5a
Include headers for pid_t.
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
69873
diff
changeset
|
25 #endif |
365 | 26 |
21849
96fd475a324d
(struct process): Make inherit_coding_system_flag a Lisp_Object.
Richard M. Stallman <rms@gnu.org>
parents:
21657
diff
changeset
|
27 /* This structure records information about a subprocess |
96fd475a324d
(struct process): Make inherit_coding_system_flag a Lisp_Object.
Richard M. Stallman <rms@gnu.org>
parents:
21657
diff
changeset
|
28 or network connection. |
96fd475a324d
(struct process): Make inherit_coding_system_flag a Lisp_Object.
Richard M. Stallman <rms@gnu.org>
parents:
21657
diff
changeset
|
29 |
96fd475a324d
(struct process): Make inherit_coding_system_flag a Lisp_Object.
Richard M. Stallman <rms@gnu.org>
parents:
21657
diff
changeset
|
30 Every field in this structure except for the first two |
96fd475a324d
(struct process): Make inherit_coding_system_flag a Lisp_Object.
Richard M. Stallman <rms@gnu.org>
parents:
21657
diff
changeset
|
31 must be a Lisp_Object, for GC's sake. */ |
365 | 32 |
33 struct Lisp_Process | |
34 { | |
85022
96eb42c9e0e3
* window.h (struct window):
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
82365
diff
changeset
|
35 EMACS_UINT size; |
365 | 36 struct Lisp_Vector *v_next; |
8888
84527c2d9f75
(struct process): New field tty_name.
Richard M. Stallman <rms@gnu.org>
parents:
7307
diff
changeset
|
37 /* Name of subprocess terminal. */ |
84527c2d9f75
(struct process): New field tty_name.
Richard M. Stallman <rms@gnu.org>
parents:
7307
diff
changeset
|
38 Lisp_Object tty_name; |
365 | 39 /* Name of this process */ |
40 Lisp_Object name; | |
43967
7e0389460d9d
(struct Lisp_Process): New member log.
Kim F. Storm <storm@cua.dk>
parents:
39935
diff
changeset
|
41 /* List of command arguments that this process was run with. |
7e0389460d9d
(struct Lisp_Process): New member log.
Kim F. Storm <storm@cua.dk>
parents:
39935
diff
changeset
|
42 Is set to t for a stopped network process; nil otherwise. */ |
365 | 43 Lisp_Object command; |
44 /* (funcall FILTER PROC STRING) (if FILTER is non-nil) | |
45 to dispose of a bunch of chars from the process all at once */ | |
46 Lisp_Object filter; | |
47 /* (funcall SENTINEL PROCESS) when process state changes */ | |
48 Lisp_Object sentinel; | |
43967
7e0389460d9d
(struct Lisp_Process): New member log.
Kim F. Storm <storm@cua.dk>
parents:
39935
diff
changeset
|
49 /* (funcall LOG SERVER CLIENT MESSAGE) when a server process |
7e0389460d9d
(struct Lisp_Process): New member log.
Kim F. Storm <storm@cua.dk>
parents:
39935
diff
changeset
|
50 accepts a connection from a client. */ |
7e0389460d9d
(struct Lisp_Process): New member log.
Kim F. Storm <storm@cua.dk>
parents:
39935
diff
changeset
|
51 Lisp_Object log; |
365 | 52 /* Buffer that output is going to */ |
53 Lisp_Object buffer; | |
95884
d6a4488883dc
Daniel Engeler <engeler at gmail.com>
Glenn Morris <rgm@gnu.org>
parents:
94994
diff
changeset
|
54 /* t if this is a real child process. For a network or serial |
d6a4488883dc
Daniel Engeler <engeler at gmail.com>
Glenn Morris <rgm@gnu.org>
parents:
94994
diff
changeset
|
55 connection, it is a plist based on the arguments to |
d6a4488883dc
Daniel Engeler <engeler at gmail.com>
Glenn Morris <rgm@gnu.org>
parents:
94994
diff
changeset
|
56 make-network-process or make-serial-process. */ |
365 | 57 Lisp_Object childp; |
49222
bfa7cad7b524
(struct Lisp_Process): New member plist replaces old
Kim F. Storm <storm@cua.dk>
parents:
49163
diff
changeset
|
58 /* Plist for programs to keep per-process state information, parameters, etc. */ |
bfa7cad7b524
(struct Lisp_Process): New member plist replaces old
Kim F. Storm <storm@cua.dk>
parents:
49163
diff
changeset
|
59 Lisp_Object plist; |
95884
d6a4488883dc
Daniel Engeler <engeler at gmail.com>
Glenn Morris <rgm@gnu.org>
parents:
94994
diff
changeset
|
60 /* Symbol indicating the type of process: real, network, serial */ |
d6a4488883dc
Daniel Engeler <engeler at gmail.com>
Glenn Morris <rgm@gnu.org>
parents:
94994
diff
changeset
|
61 Lisp_Object type; |
365 | 62 /* Marker set to end of last buffer-inserted output from this process */ |
63 Lisp_Object mark; | |
64 /* Symbol indicating status of process. | |
65 This may be a symbol: run, open, or closed. | |
66 Or it may be a list, whose car is stop, exit or signal | |
67 and whose cdr is a pair (EXIT_CODE . COREDUMP_FLAG) | |
68 or (SIGNAL_NUMBER . COREDUMP_FLAG). */ | |
69 Lisp_Object status; | |
17042
00b923d54108
(struct Lisp_Process): New members
Karl Heuer <kwzh@gnu.org>
parents:
16059
diff
changeset
|
70 /* Coding-system for decoding the input from this process. */ |
00b923d54108
(struct Lisp_Process): New members
Karl Heuer <kwzh@gnu.org>
parents:
16059
diff
changeset
|
71 Lisp_Object decode_coding_system; |
00b923d54108
(struct Lisp_Process): New members
Karl Heuer <kwzh@gnu.org>
parents:
16059
diff
changeset
|
72 /* Working buffer for decoding. */ |
00b923d54108
(struct Lisp_Process): New members
Karl Heuer <kwzh@gnu.org>
parents:
16059
diff
changeset
|
73 Lisp_Object decoding_buf; |
00b923d54108
(struct Lisp_Process): New members
Karl Heuer <kwzh@gnu.org>
parents:
16059
diff
changeset
|
74 /* Coding-system for encoding the output to this process. */ |
00b923d54108
(struct Lisp_Process): New members
Karl Heuer <kwzh@gnu.org>
parents:
16059
diff
changeset
|
75 Lisp_Object encode_coding_system; |
00b923d54108
(struct Lisp_Process): New members
Karl Heuer <kwzh@gnu.org>
parents:
16059
diff
changeset
|
76 /* Working buffer for encoding. */ |
00b923d54108
(struct Lisp_Process): New members
Karl Heuer <kwzh@gnu.org>
parents:
16059
diff
changeset
|
77 Lisp_Object encoding_buf; |
69873
2d844bbbccd4
* process.h (struct Lisp_Process): Replace Lisp_Objects `pid',
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
68651
diff
changeset
|
78 |
2d844bbbccd4
* process.h (struct Lisp_Process): Replace Lisp_Objects `pid',
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
68651
diff
changeset
|
79 /* After this point, there are no Lisp_Objects any more. */ |
81826
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
80 /* alloc.c assumes that `pid' is the first such non-Lisp slot. */ |
69873
2d844bbbccd4
* process.h (struct Lisp_Process): Replace Lisp_Objects `pid',
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
68651
diff
changeset
|
81 |
2d844bbbccd4
* process.h (struct Lisp_Process): Replace Lisp_Objects `pid',
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
68651
diff
changeset
|
82 /* Number of this process. |
2d844bbbccd4
* process.h (struct Lisp_Process): Replace Lisp_Objects `pid',
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
68651
diff
changeset
|
83 allocate_process assumes this is the first non-Lisp_Object field. |
95884
d6a4488883dc
Daniel Engeler <engeler at gmail.com>
Glenn Morris <rgm@gnu.org>
parents:
94994
diff
changeset
|
84 A value 0 is used for pseudo-processes such as network or serial |
d6a4488883dc
Daniel Engeler <engeler at gmail.com>
Glenn Morris <rgm@gnu.org>
parents:
94994
diff
changeset
|
85 connections. */ |
69873
2d844bbbccd4
* process.h (struct Lisp_Process): Replace Lisp_Objects `pid',
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
68651
diff
changeset
|
86 pid_t pid; |
81826
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
87 /* Descriptor by which we read from this process */ |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
88 int infd; |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
89 /* Descriptor by which we write to this process */ |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
90 int outfd; |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
91 /* Event-count of last event in which this process changed status. */ |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
92 int tick; |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
93 /* Event-count of last such event reported. */ |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
94 int update_tick; |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
95 /* Size of carryover in decoding. */ |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
96 int decoding_carryover; |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
97 /* Hysteresis to try to read process output in larger blocks. |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
98 On some systems, e.g. GNU/Linux, Emacs is seen as |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
99 an interactive app also when reading process output, meaning |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
100 that process output can be read in as little as 1 byte at a |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
101 time. Value is micro-seconds to delay reading output from |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
102 this process. Range is 0 .. 50000. */ |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
103 int read_output_delay; |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
104 /* Should we delay reading output from this process. |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
105 Initialized from `Vprocess_adaptive_read_buffering'. |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
106 0 = nil, 1 = t, 2 = other. */ |
92619
6c9be1557979
(struct Lisp_Process): Declare bit fields as unsigned.
Andreas Schwab <schwab@suse.de>
parents:
87649
diff
changeset
|
107 unsigned int adaptive_read_buffering : 2; |
81826
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
108 /* Skip reading this process on next read. */ |
92619
6c9be1557979
(struct Lisp_Process): Declare bit fields as unsigned.
Andreas Schwab <schwab@suse.de>
parents:
87649
diff
changeset
|
109 unsigned int read_output_skip : 1; |
81826
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
110 /* Non-nil means kill silently if Emacs is exited. |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
111 This is the inverse of the `query-on-exit' flag. */ |
92619
6c9be1557979
(struct Lisp_Process): Declare bit fields as unsigned.
Andreas Schwab <schwab@suse.de>
parents:
87649
diff
changeset
|
112 unsigned int kill_without_query : 1; |
81826
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
113 /* Non-nil if communicating through a pty. */ |
92619
6c9be1557979
(struct Lisp_Process): Declare bit fields as unsigned.
Andreas Schwab <schwab@suse.de>
parents:
87649
diff
changeset
|
114 unsigned int pty_flag : 1; |
81826
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
115 /* Flag to set coding-system of the process buffer from the |
077a1e6fd3f2
(struct Lisp_Process): Turn slots infd, outfd, kill_without_query, pty_flag,
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
75227
diff
changeset
|
116 coding_system used to decode process output. */ |
92619
6c9be1557979
(struct Lisp_Process): Declare bit fields as unsigned.
Andreas Schwab <schwab@suse.de>
parents:
87649
diff
changeset
|
117 unsigned int inherit_coding_system_flag : 1; |
69873
2d844bbbccd4
* process.h (struct Lisp_Process): Replace Lisp_Objects `pid',
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
68651
diff
changeset
|
118 /* Record the process status in the raw form in which it comes from `wait'. |
2d844bbbccd4
* process.h (struct Lisp_Process): Replace Lisp_Objects `pid',
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
68651
diff
changeset
|
119 This is to avoid consing in a signal handler. The `raw_status_new' |
2d844bbbccd4
* process.h (struct Lisp_Process): Replace Lisp_Objects `pid',
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
68651
diff
changeset
|
120 flag indicates that `raw_status' contains a new status that still |
2d844bbbccd4
* process.h (struct Lisp_Process): Replace Lisp_Objects `pid',
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
68651
diff
changeset
|
121 needs to be synced to `status'. */ |
92619
6c9be1557979
(struct Lisp_Process): Declare bit fields as unsigned.
Andreas Schwab <schwab@suse.de>
parents:
87649
diff
changeset
|
122 unsigned int raw_status_new : 1; |
69873
2d844bbbccd4
* process.h (struct Lisp_Process): Replace Lisp_Objects `pid',
Stefan Monnier <monnier@iro.umontreal.ca>
parents:
68651
diff
changeset
|
123 int raw_status; |
365 | 124 }; |
125 | |
21849
96fd475a324d
(struct process): Make inherit_coding_system_flag a Lisp_Object.
Richard M. Stallman <rms@gnu.org>
parents:
21657
diff
changeset
|
126 /* Every field in the preceding structure except for the first two |
96fd475a324d
(struct process): Make inherit_coding_system_flag a Lisp_Object.
Richard M. Stallman <rms@gnu.org>
parents:
21657
diff
changeset
|
127 must be a Lisp_Object, for GC's sake. */ |
96fd475a324d
(struct process): Make inherit_coding_system_flag a Lisp_Object.
Richard M. Stallman <rms@gnu.org>
parents:
21657
diff
changeset
|
128 |
365 | 129 #define ChannelMask(n) (1<<(n)) |
130 | |
6165
9c0cc4128da8
(chan_process, Vprocess_alist): Declared.
Richard M. Stallman <rms@gnu.org>
parents:
2432
diff
changeset
|
131 /* Indexed by descriptor, gives the process (if any) for that descriptor. */ |
6191
84fc456177e2
(chan_process): Don't specify size.
Karl Heuer <kwzh@gnu.org>
parents:
6165
diff
changeset
|
132 extern Lisp_Object chan_process[]; |
6165
9c0cc4128da8
(chan_process, Vprocess_alist): Declared.
Richard M. Stallman <rms@gnu.org>
parents:
2432
diff
changeset
|
133 |
9c0cc4128da8
(chan_process, Vprocess_alist): Declared.
Richard M. Stallman <rms@gnu.org>
parents:
2432
diff
changeset
|
134 /* Alist of elements (NAME . PROCESS). */ |
9c0cc4128da8
(chan_process, Vprocess_alist): Declared.
Richard M. Stallman <rms@gnu.org>
parents:
2432
diff
changeset
|
135 extern Lisp_Object Vprocess_alist; |
9c0cc4128da8
(chan_process, Vprocess_alist): Declared.
Richard M. Stallman <rms@gnu.org>
parents:
2432
diff
changeset
|
136 |
78501 | 137 /* True if we are about to fork off a synchronous process or if we |
365 | 138 are waiting for it. */ |
139 extern int synch_process_alive; | |
140 | |
14036 | 141 /* Communicate exit status of sync process to from sigchld_handler |
546 | 142 to Fcall_process. */ |
143 | |
365 | 144 /* Nonzero => this is a string explaining death of synchronous subprocess. */ |
145 extern char *synch_process_death; | |
146 | |
53714
77ad9650fc55
synch_process_termsig new variable.
Jan Djärv <jan.h.d@swipnet.se>
parents:
53471
diff
changeset
|
147 /* Nonzero => this is the signal number that terminated the subprocess. */ |
53726
f37373c2902a
* process.h: Add extern to synch_process_termsig.
Jan Djärv <jan.h.d@swipnet.se>
parents:
53714
diff
changeset
|
148 extern int synch_process_termsig; |
53714
77ad9650fc55
synch_process_termsig new variable.
Jan Djärv <jan.h.d@swipnet.se>
parents:
53471
diff
changeset
|
149 |
365 | 150 /* If synch_process_death is zero, |
151 this is exit code of synchronous subprocess. */ | |
152 extern int synch_process_retcode; | |
153 | |
2432
17a84e60603b
New macros NULL_DEVICE and EXEC_SUFFIXES, to give the name of the
Jim Blandy <jimb@redhat.com>
parents:
546
diff
changeset
|
154 /* The name of the file open to get a null file, or a data sink. |
97142 | 155 MS-DOS, and OS/2 redefine this. */ |
2432
17a84e60603b
New macros NULL_DEVICE and EXEC_SUFFIXES, to give the name of the
Jim Blandy <jimb@redhat.com>
parents:
546
diff
changeset
|
156 #ifndef NULL_DEVICE |
17a84e60603b
New macros NULL_DEVICE and EXEC_SUFFIXES, to give the name of the
Jim Blandy <jimb@redhat.com>
parents:
546
diff
changeset
|
157 #define NULL_DEVICE "/dev/null" |
17a84e60603b
New macros NULL_DEVICE and EXEC_SUFFIXES, to give the name of the
Jim Blandy <jimb@redhat.com>
parents:
546
diff
changeset
|
158 #endif |
52401 | 159 |
72726
c7ba95ddeb1d
(inhibit_sentinels): Add decl.
Richard M. Stallman <rms@gnu.org>
parents:
70209
diff
changeset
|
160 /* Nonzero means don't run process sentinels. This is used |
c7ba95ddeb1d
(inhibit_sentinels): Add decl.
Richard M. Stallman <rms@gnu.org>
parents:
70209
diff
changeset
|
161 when exiting. */ |
c7ba95ddeb1d
(inhibit_sentinels): Add decl.
Richard M. Stallman <rms@gnu.org>
parents:
70209
diff
changeset
|
162 extern int inhibit_sentinels; |
c7ba95ddeb1d
(inhibit_sentinels): Add decl.
Richard M. Stallman <rms@gnu.org>
parents:
70209
diff
changeset
|
163 |
97366
d2c211c8ceda
(w32_list_system_processes, w32_system_process_attributes): Add prototypes.
Eli Zaretskii <eliz@gnu.org>
parents:
97142
diff
changeset
|
164 extern Lisp_Object w32_list_system_processes P_ ((void)); |
d2c211c8ceda
(w32_list_system_processes, w32_system_process_attributes): Add prototypes.
Eli Zaretskii <eliz@gnu.org>
parents:
97142
diff
changeset
|
165 extern Lisp_Object w32_system_process_attributes P_ ((Lisp_Object)); |
d2c211c8ceda
(w32_list_system_processes, w32_system_process_attributes): Add prototypes.
Eli Zaretskii <eliz@gnu.org>
parents:
97142
diff
changeset
|
166 |
d2c211c8ceda
(w32_list_system_processes, w32_system_process_attributes): Add prototypes.
Eli Zaretskii <eliz@gnu.org>
parents:
97142
diff
changeset
|
167 extern Lisp_Object Qeuid, Qegid, Qcomm, Qstate, Qppid, Qpgrp, Qsess, Qttname; |
d2c211c8ceda
(w32_list_system_processes, w32_system_process_attributes): Add prototypes.
Eli Zaretskii <eliz@gnu.org>
parents:
97142
diff
changeset
|
168 extern Lisp_Object Qminflt, Qmajflt, Qcminflt, Qcmajflt, Qutime, Qstime; |
d2c211c8ceda
(w32_list_system_processes, w32_system_process_attributes): Add prototypes.
Eli Zaretskii <eliz@gnu.org>
parents:
97142
diff
changeset
|
169 extern Lisp_Object Qcutime, Qpri, Qnice, Qthcount, Qstart, Qvsize, Qrss, Qargs; |
d2c211c8ceda
(w32_list_system_processes, w32_system_process_attributes): Add prototypes.
Eli Zaretskii <eliz@gnu.org>
parents:
97142
diff
changeset
|
170 extern Lisp_Object Quser, Qgroup, Qetime, Qpcpu, Qpmem, Qtpgid, Qcstime; |
d2c211c8ceda
(w32_list_system_processes, w32_system_process_attributes): Add prototypes.
Eli Zaretskii <eliz@gnu.org>
parents:
97142
diff
changeset
|
171 |
52401 | 172 /* arch-tag: dffedfc4-d7bc-4b58-a26f-c16155449c72 |
173 (do not change this comment) */ |