aboutsummaryrefslogtreecommitdiffstats
path: root/libtests/rc4.cc
diff options
context:
space:
mode:
authorJay Berkenbilt <ejb@ql.org>2013-02-24 03:46:21 +0100
committerJay Berkenbilt <ejb@ql.org>2013-03-04 22:45:16 +0100
commit30027481f7f9e9191f7c8deea51850b7a76b1b1f (patch)
tree815af293c2f6e38994e6096a4499be0dc9a476f9 /libtests/rc4.cc
parentbabb47948a408ebad12c452ba3fdd78782360167 (diff)
downloadqpdf-30027481f7f9e9191f7c8deea51850b7a76b1b1f.tar.zst
Remove all old-style casts from C++ code
Diffstat (limited to 'libtests/rc4.cc')
-rw-r--r--libtests/rc4.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/libtests/rc4.cc b/libtests/rc4.cc
index 1328fc85..59a9265e 100644
--- a/libtests/rc4.cc
+++ b/libtests/rc4.cc
@@ -17,7 +17,7 @@ int main(int argc, char* argv[])
char* hexkey = argv[1];
char* infilename = argv[2];
char* outfilename = argv[3];
- unsigned int hexkeylen = (unsigned int)strlen(hexkey);
+ unsigned int hexkeylen = strlen(hexkey);
unsigned int keylen = hexkeylen / 2;
unsigned char* key = new unsigned char[keylen + 1];
key[keylen] = '\0';
@@ -37,7 +37,7 @@ int main(int argc, char* argv[])
t[2] = '\0';
long val = strtol(t, 0, 16);
- key[i/2] = (unsigned char) val;
+ key[i/2] = static_cast<unsigned char>(val);
}
FILE* outfile = fopen(outfilename, "wb");