miurahr / pyppmd

pyppmd provides classes and functions for compressing and decompressing text data, using PPM (Prediction by partial matching) compression algorithm variation H and I.2. It provide an API similar to Python's zlib/bz2/lzma modules.

Home Page:https://pyppmd.readthedocs.io/en/latest/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ppmd8dec: Access violation is reported on Windows

miurahr opened this issue · comments

Describe the bug
When test ppmd8 decompression on windows, access violation is reported.

Related issue
#32 #33 #34 #44

To Reproduce
CI reported on windows tox test

Environment (please complete the following information):

  • OS: Windows 10
  • Python: CPython 3.6, 3.7, 3.8, 3.9, 3.10
  • project version: main branch[db70d43]

Additional context
This may happened because pthread wrapper for windows seems incomplete, and break synchronization of threads.
By investigation, Ppmd8T_decode() is blocked in line 1 where taking mutex lock, and worker thread is live and write to output buffer that has not configured yet. Status variable indicate worker thread is finished, but it is wrongly live.

#46 might fix the issue