[hackers] [sbase] Add proper casts and fix a small error || FRIGN
commit 0f90528df7c739892c035536a519431a2a419cec
Author: FRIGN <dev_AT_frign.de>
Date: Sun Jan 11 20:29:27 2015 +0100
Add proper casts and fix a small error
diff --git a/tr.c b/tr.c
index 764e799..828adba 100644
--- a/tr.c
+++ b/tr.c
_AT_@ -26,7 +26,7 @@ static struct {
{ "digit", iswdigit },
{ "graph", iswgraph },
{ "lower", iswlower },
- { "print", iswlower },
+ { "print", iswprint },
{ "punct", iswpunct },
{ "space", iswspace },
{ "upper", iswupper },
_AT_@ -227,7 +227,7 @@ read:
goto write;
}
}
- if (set1check && set1check(r)) {
+ if (set1check && set1check((wint_t)r)) {
if (dflag && !cflag)
goto read;
if (sflag) {
_AT_@ -237,9 +237,9 @@ read:
goto write;
}
if (set1check == iswupper && set2check == iswlower)
- r = towlower(r);
+ r = towlower((wint_t)r);
if (set1check == iswlower && set2check == iswupper)
- r = towupper(r);
+ r = towupper((wint_t)r);
}
if (dflag && cflag)
goto read;
Received on Sun Jan 11 2015 - 23:35:20 CET
This archive was generated by hypermail 2.3.0
: Sun Jan 11 2015 - 23:36:11 CET