micropython/ports/unix
David Lechner 5e6cee07ab unix/mpthreadport: Fix crash when thread stack size <= 8k.
The stack size adjustment for detecting stack overflow in threads was not
taking into account that the requested stack size could be <= 8k, in which
case the subtraction would overflow.  This is fixed in this commit by
ensuring that the adjustment can't be more than the available size.

This fixes the test tests/thread/thread_stacksize1.py which sometimes
crashes with a segmentation fault because of an uncaught NLR jump, which is
a "maximum recursion depth exceeded" exception.

Suggested-by: @dpgeorge
2020-03-27 13:59:18 +11:00
..
coverage-frzmpy
coverage-frzstr
variants unix: Enable uasyncio C helper module on coverage build. 2020-03-26 01:25:45 +11:00
.gitignore unix: Rename unix binaries to micropython-variant (not _variant). 2020-01-12 10:37:40 +11:00
Makefile unix: Remove custom file implementation to use extmod's VFS POSIX one. 2020-03-18 21:01:07 +11:00
alloc.c all: Reformat C and Python source code with tools/codeformat.py. 2020-02-28 10:33:03 +11:00
coverage.c unix/coverage: Init all pairheap test nodes before using them. 2020-03-26 01:21:04 +11:00
fatfs_port.c
gccollect.c all: Reformat C and Python source code with tools/codeformat.py. 2020-02-28 10:33:03 +11:00
input.c all: Reformat C and Python source code with tools/codeformat.py. 2020-02-28 10:33:03 +11:00
input.h
main.c unix: Remove custom file implementation to use extmod's VFS POSIX one. 2020-03-18 21:01:07 +11:00
manifest.py tools/makemanifest.py: Eval relative paths w.r.t. current manifest file. 2019-10-21 23:01:41 +11:00
manifest_coverage.py unix: Convert to use FROZEN_MANIFEST to specify frozen code. 2019-10-15 21:35:27 +11:00
modffi.c all: Reformat C and Python source code with tools/codeformat.py. 2020-02-28 10:33:03 +11:00
modjni.c all: Reformat C and Python source code with tools/codeformat.py. 2020-02-28 10:33:03 +11:00
modmachine.c all: Reformat C and Python source code with tools/codeformat.py. 2020-02-28 10:33:03 +11:00
modos.c windows/msvc: Fix warnings regarding function declarations. 2020-03-25 00:38:11 +11:00
modtermios.c all: Reformat C and Python source code with tools/codeformat.py. 2020-02-28 10:33:03 +11:00
modtime.c all: Reformat C and Python source code with tools/codeformat.py. 2020-02-28 10:33:03 +11:00
moduos_vfs.c all: Reformat C and Python source code with tools/codeformat.py. 2020-02-28 10:33:03 +11:00
moduselect.c unix: Remove custom file implementation to use extmod's VFS POSIX one. 2020-03-18 21:01:07 +11:00
modusocket.c all: Reformat C and Python source code with tools/codeformat.py. 2020-02-28 10:33:03 +11:00
mpconfigport.h unix: Remove custom definition of MP_PLAT_PRINT_STRN. 2020-03-25 00:54:18 +11:00
mpconfigport.mk
mphalport.h all: Reformat C and Python source code with tools/codeformat.py. 2020-02-28 10:33:03 +11:00
mpthreadport.c unix/mpthreadport: Fix crash when thread stack size <= 8k. 2020-03-27 13:59:18 +11:00
mpthreadport.h
qstrdefsport.h all: Add *FORMAT-OFF* in various places. 2020-02-28 10:31:07 +11:00
unix_mphal.c unix,windows: Use STDIN_FILENO, STDOUT_FILENO macros where appropriate. 2020-03-25 00:59:05 +11:00