Mercurial > cpython-lru_cache-weakref
annotate Python/sigcheck.c @ 13658:f79434ee41fa legacy-trunk
Mass ANSIfication of function definitions. Doesn't cover all 'extern'
declarations yet, those come later.
| author | Thomas Wouters <thomas@python.org> |
|---|---|
| date | Sat, 22 Jul 2000 18:47:25 +0000 |
| parents | 87ee82e5c56d |
| children | 6f6f965c5e2d |
| rev | line source |
|---|---|
|
1660
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
1 /*********************************************************** |
|
13255
916fb024ce94
Change copyright notice.
Guido van Rossum <guido@python.org>
parents:
5373
diff
changeset
|
2 Copyright (c) 2000, BeOpen.com. |
|
916fb024ce94
Change copyright notice.
Guido van Rossum <guido@python.org>
parents:
5373
diff
changeset
|
3 Copyright (c) 1995-2000, Corporation for National Research Initiatives. |
|
916fb024ce94
Change copyright notice.
Guido van Rossum <guido@python.org>
parents:
5373
diff
changeset
|
4 Copyright (c) 1990-1995, Stichting Mathematisch Centrum. |
|
916fb024ce94
Change copyright notice.
Guido van Rossum <guido@python.org>
parents:
5373
diff
changeset
|
5 All rights reserved. |
|
1660
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
6 |
|
13255
916fb024ce94
Change copyright notice.
Guido van Rossum <guido@python.org>
parents:
5373
diff
changeset
|
7 See the file "Misc/COPYRIGHT" for information on usage and |
|
916fb024ce94
Change copyright notice.
Guido van Rossum <guido@python.org>
parents:
5373
diff
changeset
|
8 redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES. |
|
1660
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
9 ******************************************************************/ |
|
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
10 |
|
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
11 /* Sigcheck is similar to intrcheck() but sets an exception when an |
|
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
12 interrupt occurs. It can't be in the intrcheck.c file since that |
|
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
13 file (and the whole directory it is in) doesn't know about objects |
|
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
14 or exceptions. It can't be in errors.c because it can be |
|
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
15 overridden (at link time) by a more powerful version implemented in |
|
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
16 signalmodule.c. */ |
|
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
17 |
|
5373
5880384d7c71
Quickly renamed the remaining files -- this directory is done.
Guido van Rossum <guido@python.org>
parents:
4503
diff
changeset
|
18 #include "Python.h" |
|
1660
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
19 |
|
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
20 /* ARGSUSED */ |
|
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
21 int |
|
13658
f79434ee41fa
Mass ANSIfication of function definitions. Doesn't cover all 'extern'
Thomas Wouters <thomas@python.org>
parents:
13256
diff
changeset
|
22 PyErr_CheckSignals(void) |
|
1660
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
23 { |
|
5373
5880384d7c71
Quickly renamed the remaining files -- this directory is done.
Guido van Rossum <guido@python.org>
parents:
4503
diff
changeset
|
24 if (!PyOS_InterruptOccurred()) |
|
1660
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
25 return 0; |
|
5373
5880384d7c71
Quickly renamed the remaining files -- this directory is done.
Guido van Rossum <guido@python.org>
parents:
4503
diff
changeset
|
26 PyErr_SetNone(PyExc_KeyboardInterrupt); |
|
1660
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
27 return -1; |
|
ffd495bacbd4
Replace intrcheck() by sigcheck() in many places.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
28 } |
