(no subject)

Date: 2008-08-05 04:27 am (UTC)
You're seeing the difference between a signed char and an unsigned char (why does C say char can have a sign? who knows). Bitwise, they are the same value: http://en.wikipedia.org/wiki/Two%27s_complement

It's worth noting that man 3 getopt (first point of call) tells you that -1 is returned when there are no more options to pass and that getopt() returns an 'int', not a 'char'.
This account has disabled anonymous posting.
If you don't have an account you can create one now.
HTML doesn't work in the subject.
More info about formatting

April 2023

S M T W T F S
      1
2345678
91011121314 15
16171819202122
23242526272829
30      

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Jul. 2nd, 2025 07:49 pm
Powered by Dreamwidth Studios