Rev 3627 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 3627 | Rev 3630 | ||
---|---|---|---|
Line 77... | Line 77... | ||
77 | } |
77 | } |
78 | 78 | ||
79 | static inline int tolower(int c) |
79 | static inline int tolower(int c) |
80 | { |
80 | { |
81 | if (isupper(c)) |
81 | if (isupper(c)) |
82 | return (c + ('a' - 'A' > 0 ? 'a' - 'A' : 'A' - 'a')); |
82 | return (c + ('a' - 'A')); |
83 | else |
83 | else |
84 | return c; |
84 | return c; |
85 | } |
85 | } |
86 | 86 | ||
87 | static inline int toupper(int c) |
87 | static inline int toupper(int c) |
88 | { |
88 | { |
89 | if (islower(c)) |
89 | if (islower(c)) |
90 | return (c - ('a' - 'A' > 0 ? 'a' - 'A' : 'A' - 'a')); |
90 | return (c + ('A' - 'a')); |
91 | else |
91 | else |
92 | return c; |
92 | return c; |
93 | } |
93 | } |
94 | 94 | ||
95 | #endif |
95 | #endif |