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

Assumes char is signed #14

Open
arpruss opened this issue Aug 15, 2024 · 2 comments
Open

Assumes char is signed #14

arpruss opened this issue Aug 15, 2024 · 2 comments

Comments

@arpruss
Copy link
Contributor

arpruss commented Aug 15, 2024

in main(), the getopt() return value is assigned to char c, and then compared against -1. This fails on systems (like my Raspberry PI) where char is unsigned. Instead, c should be declared int.

@sshipway
Copy link
Owner

yes, good point. This used to work back 40 years ago when I first wrote it! Care to submit a PR to fix?

@arpruss
Copy link
Contributor Author

arpruss commented Aug 16, 2024

I had really enjoyed this about 35 years ago, and so I downloaded it and compiled it today. Worked great on Windows/Cygwin, but then got this hiccup.

I'll see if I can figure out how to do a PR. I haven't yet done any PRs since github disabled svn access.

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

No branches or pull requests

2 participants