mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
YUV420pFrame::BufferRGBA: fix uninitialized width/height
- This fixes a video recording crash that manifested randomly, but more often when repeatedly quickly starting and stopping a recording - The first video frame had uninitialized memory that left it up to chance whether an internal buffer was correctly sized (SIGSEGV)
This commit is contained in:
parent
f442f933fc
commit
df7b13499f
1 changed files with 3 additions and 2 deletions
|
|
@ -1,6 +1,6 @@
|
||||||
// RING RACERS
|
// RING RACERS
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
// Copyright (C) 2023 by James Robert Roman
|
// Copyright (C) 2023-2024 by James Robert Roman
|
||||||
//
|
//
|
||||||
// This program is free software distributed under the
|
// This program is free software distributed under the
|
||||||
// terms of the GNU General Public License, version 2.
|
// terms of the GNU General Public License, version 2.
|
||||||
|
|
@ -36,7 +36,8 @@ public:
|
||||||
int height() const { return height_; }
|
int height() const { return height_; }
|
||||||
|
|
||||||
private:
|
private:
|
||||||
int width_, height_;
|
int width_ = 0;
|
||||||
|
int height_ = 0;
|
||||||
|
|
||||||
std::vector<uint8_t> vec_;
|
std::vector<uint8_t> vec_;
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue