Comments (3)
copy_fh is defined the same way in its prototype and its implementation: static int copy_fh(struct mspack_system *, struct mspack_file *, struct mspack_file *, size_t, unsigned char *, int)
It is called with the fourth parameter being unsigned int
rather than size_t
. As size_t is the same or higher rank than unsigned int, and both are unsigned, it should be promoted to size_t without warning or error.
Please supply the error output by gcc, and also supply the output of changing "gcc -c" (compile) to "gcc -E" (preprocessor output) so that the definition of size_t is revealed.
from libmspack.
The declaration of copy_fh is on line 38 and the definition is on line 377. The declaration and definitions are not the same, gcc complains with
CC mspack/oabd.lo
mspack/oabd.c:375:12: error: conflicting types for ‘copy_fh’
375 | static int copy_fh(struct mspack_system *sys, struct mspack_file *infh,
| ^~~~~~~
mspack/oabd.c:37:12: note: previous declaration of ‘copy_fh’ was here
37 | static int copy_fh(struct mspack_system *sys, struct mspack_file *infh,
| ^~~~~~~
mspack/oabd.c:37:12: warning: ‘copy_fh’ used but never defined
mspack/oabd.c:375:12: warning: ‘copy_fh’ defined but not used [-Wunused-function]
375 | static int copy_fh(struct mspack_system *sys, struct mspack_file *infh,
| ^~~~~~~
make[1]: *** [Makefile:1071: mspack/oabd.lo] Error 1
make[1]: Leaving directory '/src/mail/libmspack-1.9.1/libmspack'
make: *** [Makefile:718: all] Error 2
from libmspack.
OK, you are using an outdated libmspack. This was fixed in 817f2a2 and released in libmspack v0.10.1alpha.
I believe this happened: you skipped the README on the front of the repository, went to the "releases" page and clicked whatever was first in the list. This gave you a snapshot of the repository for cabextract v1.9.1, and did not give you a snapshot of the repository for libmspack* v0.10.1alpha, which is what you need, if for some reason you don't want to go to https://www.cabextract.org.uk/libmspack/ where libmspack is actually released.
Solution: Read the README and obtain libmspack from https://www.cabextract.org.uk/libmspack/
If you are doing packaging for a distro, please ensure https://www.cabextract.org.uk/libmspack/ is where the package comes from, not a third party such as GitHub.
from libmspack.
Related Issues (20)
- cabextract doesn't build from master HOT 2
- memory exhausted in oabd_decompress() HOT 2
- memory exhausted in chmd_read_headers() HOT 1
- Heap buffer overflow in chmd_read_headers() HOT 7
- Multiple filters in one command HOT 6
- 1.9.1: issue with dist tar ball HOT 2
- Not clear on Github how to get libmspack vs cabextract releases HOT 17
- chmextract HOT 2
- configure / libtool fails with -flto HOT 12
- configure / libtool fails with -flto HOT 6
- Compilier warnings with 1.9.1 HOT 4
- Compiler error with 1.9.1 / gcc 9.3.1 HOT 5
- Malloc size error in chmd.c:1327:34 HOT 2
- extra = 0 confusion HOT 4
- build fails on macos HOT 1
- cabextract: Writing into symlinks HOT 11
- Issue with KWAJ method 2 decompression HOT 2
- Fail to properly create path components coming from the archive HOT 3
- Cannot extract files from a .cab file containing file names encoded in shift_JIS HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from libmspack.