summaryrefslogtreecommitdiff
path: root/misc.cc
diff options
context:
space:
mode:
Diffstat (limited to 'misc.cc')
-rw-r--r--misc.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/misc.cc b/misc.cc
index 5eb81b5..0c71de2 100644
--- a/misc.cc
+++ b/misc.cc
@@ -23,7 +23,7 @@ namespace misc {
data.reserve(d_size);
char buf[2];
- for(int i=0; i<s_size; i++){
+ for(size_t i=0; i<s_size; i++){
char c = hexString[i];
bool char_from_range = (('0' <= c && c <='9') || ('A' <= c && c <= 'F') || ('a' <= c && c<= 'f'));
@@ -47,7 +47,7 @@ namespace misc {
for (const char *pend = p + size; p < pend;) {
if (print_header){
- snprintf(formatbuf, 128, "%04lx\t", p - pstart);
+ snprintf(formatbuf, 128, "%04dx\t", static_cast<int> (p - pstart));
out << formatbuf;
}