Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Address issue #36 #46

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Address issue #36 #46

wants to merge 2 commits into from

Conversation

mzpqnxow
Copy link

This is a tiny patch that fixes #36 with a code change

I understand that it's possible to use CFLAGS to make newer versions of gcc accept the code "as-is" but in my opinion it's better to address it this way by moving the declaration of verbose into a single .c and accessing it as an extern elsewhere.

Because verbose is only accessed directly in unsquash.c (by the command-line flag parsing code) I put it there, it seemed the most logical

For whatever reason I wasn't able to create a clean patch to your patch, so rather than replace the entire patch0.txt with the changes, I added a patch1.txt. I assume you'll want to coalesce these into one if you decide to accept this

I didn't do extensive testing on the change but it builds and functions as expected both with and without the -trace flag. I tested by building (obviously), extracting a few squashfs filesystems I had laying around and making sure the trace output showed up and there weren't any runtime symbol resolution errors

Thanks for all your work on binwalk and embedded RE in general!

@mzpqnxow
Copy link
Author

mzpqnxow commented Feb 6, 2022

Hello @devttys0 would you like to merge this or should I close it out? It's been discussed elsewhere in this repository (#36) and in binwalk (ReFirmLabs/binwalk#588) and a few people have pasted fixes into the issues, but there hasn't been a PR or fix committed

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Debian / gcc / g++ gcc (Debian 10.2.0-15) 10.2.0 : fails to compile
1 participant