Mercurial > emacs
annotate msdos/sigaction.c @ 88954:363e137c2601
(archive-file-name-coding-system): New variable.
Make it permanent-local.
(byte-after, bref, insert-unibyte): New function. Change most of
char-after, aref, insert to them respectively.
(archive-mode): Set archive-file-name-coding-system.
(archive-summarize): Don't change the buffer's multibyteness.
(archive-extract): Inherit archive-file-name-coding-system from
archive-superior-buffer. Bind coding-system-for-write to
archive-file-name-coding-system.
(archive-*-write-file-member): Encode ENAME by
archive-file-name-coding-system. Bind coding-system-for-write to
no-conversion.
(archive-rename-entry): Encode the filename by
archive-file-name-coding-system.
(archive-mode-revert): Don't change the buffer's multibyteness.
(archive-arc-summarize, archive-lzh-summarize,
archive-zoo-summarize): Don't change the buffer's multibyteness.
Decode filenames by archive-file-name-coding-system.
(archive-arc-rename-entry, archive-zip-chmod-entry): Don't change
the buffer's multibyteness.
author | Kenichi Handa <handa@m17n.org> |
---|---|
date | Wed, 31 Jul 2002 07:14:13 +0000 |
parents | 354e0c45cedf |
children | 695cf19ef79e |
rev | line source |
---|---|
25856 | 1 /* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */ |
2 #include <signal.h> | |
3 #include <errno.h> | |
4 | |
5 int | |
6 sigaction(int _sig, const struct sigaction *_act, struct sigaction *_oact) | |
7 { | |
8 int retval = 0; | |
9 | |
10 if (_oact) | |
11 { | |
12 void (*installed_sig)(int) = signal (_sig, SIG_IGN); | |
13 | |
14 /* FIXME */ | |
15 if (installed_sig == SIG_ERR) | |
16 { | |
17 retval = -1; | |
18 errno = EINVAL; | |
19 } | |
20 else | |
21 signal (_sig, installed_sig); | |
22 _oact->sa_handler = installed_sig; | |
23 retval = sigemptyset (&_oact->sa_mask); | |
24 _oact->sa_flags = 0; | |
25 } | |
26 if (_act) | |
27 { | |
28 if (signal (_sig, _act->sa_handler) == SIG_ERR) | |
29 { | |
30 retval = -1; | |
31 errno = EINVAL; | |
32 } | |
33 } | |
34 return 0; | |
35 } | |
36 | |
37 | |
38 |