1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-12-24 22:14:36 +02:00

fix indentation

This commit is contained in:
Andrey Filipenkov 2023-02-24 12:58:23 +03:00
parent e6d87d5f35
commit 176dfca578

View File

@ -20,6 +20,8 @@
#include <cstdio>
#define GETFILE static_cast<std::FILE*>(filePtr)
#ifdef VCMI_WINDOWS
#ifndef _CRT_SECURE_NO_WARNINGS
#define _CRT_SECURE_NO_WARNINGS
@ -43,12 +45,10 @@ inline FILE* do_open(const CharType* name, const CharType* mode)
#endif
}
#define GETFILE static_cast<std::FILE*>(filePtr)
voidpf ZCALLBACK MinizipOpenFunc(voidpf opaque, const void* filename, int mode)
{
const CharType* mode_fopen = [mode]() -> const CharType*
{
const CharType* mode_fopen = [mode]() -> const CharType*
{
if ((mode & ZLIB_FILEFUNC_MODE_READWRITEFILTER) == ZLIB_FILEFUNC_MODE_READ)
return CHAR_LITERAL("rb");
else if (mode & ZLIB_FILEFUNC_MODE_EXISTING)
@ -56,10 +56,10 @@ voidpf ZCALLBACK MinizipOpenFunc(voidpf opaque, const void* filename, int mode)
else if (mode & ZLIB_FILEFUNC_MODE_CREATE)
return CHAR_LITERAL("wb");
return nullptr;
}();
}();
if (filename != nullptr && mode_fopen != nullptr)
return do_open(static_cast<const CharType*>(filename), mode_fopen);
if (filename != nullptr && mode_fopen != nullptr)
return do_open(static_cast<const CharType*>(filename), mode_fopen);
else
return nullptr;
}