aboutsummaryrefslogtreecommitdiff
path: root/engines/zvision
diff options
context:
space:
mode:
authorrichiesams2013-07-18 14:43:16 -0500
committerrichiesams2013-08-04 13:32:26 -0500
commit125a061a9650297d81a76cc8e77033ca099191b0 (patch)
tree0b2bd70f7279168da6674a80f60900c9e758126f /engines/zvision
parent1c44fe7afba706400dd8d3c2132f47da4e07ac1e (diff)
downloadscummvm-rg350-125a061a9650297d81a76cc8e77033ca099191b0.tar.gz
scummvm-rg350-125a061a9650297d81a76cc8e77033ca099191b0.tar.bz2
scummvm-rg350-125a061a9650297d81a76cc8e77033ca099191b0.zip
ZVISION: Convert to using MKTAG() instead of checking each char individually
Diffstat (limited to 'engines/zvision')
-rw-r--r--engines/zvision/image.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/engines/zvision/image.cpp b/engines/zvision/image.cpp
index 981308fa31..6e6b802739 100644
--- a/engines/zvision/image.cpp
+++ b/engines/zvision/image.cpp
@@ -42,11 +42,11 @@ void ZVision::renderImageToScreen(const Common::String &fileName, uint32 x, uint
// Read the magic number
// Some files are true TGA, while others are TGZ
- char fileType[4];
- file.read(fileType, 4);
+ uint32 fileType;
+ fileType = file.readUint32BE();
// Check for TGZ files
- if (fileType[0] == 'T' && fileType[1] == 'G' && fileType[2] == 'Z' && fileType[3] == '\0') {
+ if (fileType == MKTAG('T', 'G', 'Z', '\0')) {
// TGZ files have a header and then Bitmap data that is compressed with LZSS
uint32 decompressedSize = file.readSint32LE();
uint32 width = file.readSint32LE();