Add support for PKZIP compression for 3D models
Description
KiCad crash when try to load a wrong format STEPZ file. I my case I had tried a wrong compressed format but hopped the KiCad will warning me instead of crash.
This issue may be related with the commit d0e43ab9
Steps to reproduce
- Open the Footprint Properties >> 3D Settings >> Add new 3D model;
- Load a STEPZ file with wrong compression;
- KiCad crash instead of warning user of a invalid file format.
You can use this "wrong compressed" (I had used ZIP instead GZ) file to debug: NI_crio-mod_db_37.stpz
The right one is this: NI_crio-mod_db_37__copy_.stpz
See the video at 45 seconds (the video have to be downloaded to work):
KiCad Version
Application: Pcbnew
Version: 5.99.0-unknown-a97f2fb22~90~ubuntu20.04.1, release build
Libraries:
wxWidgets 3.0.4
Platform: Linux 5.4.0-42-generic x86_64, 64 bit, Little endian, wxGTK
wxWidgets: 3.0.4 (wchar_t,wx containers,compatible with 2.8) GTK+ 3.24
Boost: 1.71.0
OCE: 6.9.1
Curl: 7.68.0
ngspice: 31
Compiler: GCC 9.3.0 with C++ ABI 1013
Build settings:
KICAD_SCRIPTING=ON
KICAD_SCRIPTING_MODULES=ON
KICAD_SCRIPTING_PYTHON3=ON
KICAD_SCRIPTING_WXPYTHON=ON
KICAD_SCRIPTING_WXPYTHON_PHOENIX=ON
KICAD_SCRIPTING_ACTION_MENU=ON
BUILD_GITHUB_PLUGIN=ON
KICAD_USE_OCE=ON
KICAD_SPICE=ON