diff options
author | 2023-09-05 17:10:24 +0200 | |
---|---|---|
committer | 2023-09-06 01:10:24 +1000 | |
commit | 1c61ccfe840cdae7a9f92292946a45f3b47e2412 (patch) | |
tree | b56d4b69b96e314abcf56407da44705a602727f1 /3rdparty/bx/src/settings.cpp | |
parent | b2c399c61d65063ae95e8387d34b098e9516b1a9 (diff) |
Updated bgfx, bx and bimg to current upstream versions. (#11493)
* Reverted "macOS, iOS: Removed OpenGL/OpenGLES support. (commit 4693983242a698eaafed87faf4ffef1789adc8f9).
* Reverted "Fix macOS build" (commit ce2c2c13eda7d699051f75f598e740a447343a88).
* Reverted "macOS: Fixed deprecated warnings." (commit 10a8cb61f882ebc9bb376ee2341d003880b7037f).
* Added bgfx/README.mame explaining deviations from upstream.
Diffstat (limited to '3rdparty/bx/src/settings.cpp')
-rw-r--r-- | 3rdparty/bx/src/settings.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/3rdparty/bx/src/settings.cpp b/3rdparty/bx/src/settings.cpp index 7f16eeee10f..87e37bb60e8 100644 --- a/3rdparty/bx/src/settings.cpp +++ b/3rdparty/bx/src/settings.cpp @@ -1,5 +1,5 @@ /* - * Copyright 2011-2022 Branimir Karadzic. All rights reserved. + * Copyright 2011-2023 Branimir Karadzic. All rights reserved. * License: https://github.com/bkaradzic/bx/blob/master/LICENSE */ @@ -7,8 +7,8 @@ namespace { -#define INI_MALLOC(_ctx, _size) (BX_ALLOC(reinterpret_cast<bx::AllocatorI*>(_ctx), _size) ) -#define INI_FREE(_ctx, _ptr) (BX_FREE(reinterpret_cast<bx::AllocatorI*>(_ctx), _ptr) ) +#define INI_MALLOC(_ctx, _size) (bx::alloc(reinterpret_cast<bx::AllocatorI*>(_ctx), _size) ) +#define INI_FREE(_ctx, _ptr) (bx::free(reinterpret_cast<bx::AllocatorI*>(_ctx), _ptr) ) #define INI_MEMCPY(_dst, _src, _count) (bx::memCopy(_dst, _src, _count) ) #define INI_STRLEN(_str) (bx::strLen(_str) ) #define INI_STRNICMP(_s1, _s2, _len) (bx::strCmpI(_s1, _s2, _len) ) @@ -170,12 +170,12 @@ int32_t Settings::read(ReaderSeekerI* _reader, Error* _err) { int32_t size = int32_t(getRemain(_reader) ); - void* data = BX_ALLOC(m_allocator, size); + void* data = bx::alloc(m_allocator, size); int32_t total = bx::read(_reader, data, size, _err); load(data, size); - BX_FREE(m_allocator, data); + bx::free(m_allocator, data); return total; } @@ -185,12 +185,12 @@ int32_t Settings::write(WriterI* _writer, Error* _err) const ini_t* ini = INI_T(m_ini); int32_t size = ini_save(ini, NULL, 0); - void* data = BX_ALLOC(m_allocator, size); + void* data = bx::alloc(m_allocator, size); ini_save(ini, (char*)data, size); int32_t total = bx::write(_writer, data, size-1, _err); - BX_FREE(m_allocator, data); + bx::free(m_allocator, data); return total; } |