Skip to content

Commit 85dbd4b

Browse files
committed
Stackless issue python#167: replace printf() by PySys_WriteStderr()
printf() was used to emit parts of an error message, if there is a pending error while entering Stackless subsystem. (cherry picked from commit 8a44a5f)
1 parent b248ae8 commit 85dbd4b

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

Stackless/changelog.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,11 @@ What's New in Stackless 3.X.X?
99

1010
*Release date: 20XX-XX-XX*
1111

12+
- https://github.com/stackless-dev/stackless/issues/167
13+
Replace 'printf(...)' calls by PySys_WriteStderr(...). They are used to emit
14+
an error message, if there is a pending error while entering Stackless
15+
subsystem.
16+
1217
- https://github.com/stackless-dev/stackless/issues/154
1318
Fix a minor bug in STACKLESS_PROMOTE_WRAPPER and STACKLESS_PROMOTE_METHOD.
1419

Stackless/module/scheduling.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1288,9 +1288,9 @@ slp_initialize_main_and_current(void)
12881288
Py_XINCREF(value);
12891289
Py_XINCREF(traceback);
12901290
PyErr_Restore(type, value, traceback);
1291-
printf("Pending error while entering Stackless subsystem:\n");
1291+
PySys_WriteStderr("Pending error while entering Stackless subsystem:\n");
12921292
PyErr_Print();
1293-
printf("Above exception is re-raised to the caller.\n");
1293+
PySys_WriteStderr("Above exception is re-raised to the caller.\n");
12941294
PyErr_Restore(type, value, traceback);
12951295
#endif
12961296
return 1;

0 commit comments

Comments
 (0)