aboutsummaryrefslogtreecommitdiff
path: root/image_utils.h
diff options
context:
space:
mode:
Diffstat (limited to 'image_utils.h')
-rw-r--r--image_utils.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/image_utils.h b/image_utils.h
index 3d4a83a..3bd7a79 100644
--- a/image_utils.h
+++ b/image_utils.h
@@ -176,8 +176,8 @@ constexpr ExecutableType CastToExecutableType(uint32_t possible_exe_type) {
inline std::string CastExecutableTypeToString(ExecutableType exe_type) {
uint32_t v = static_cast<uint32_t>(exe_type);
- char result[] = {v & 0xFF, (v >> 8) & 0xFF, (v >> 16) & 0xFF,
- (v >> 24) & 0xFF, 0};
+ char result[] = {static_cast<char>(v), static_cast<char>(v >> 8),
+ static_cast<char>(v >> 16), static_cast<char>(v >> 24), 0};
return result;
}