mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-31 01:11:06 +02:00
cc_draw: ensure unsigned values
avoids possible signed integer overflow runtime errors
Origin commit data
------------------
Branch: ni/coolstream
Commit: 9874a589c7
Author: Thilo Graf <dbt@novatux.de>
Date: 2021-12-02 (Thu, 02 Dec 2021)
------------------
This commit was generated by Migit
This commit is contained in:
@@ -908,12 +908,12 @@ int CCDraw::getYPos() const
|
||||
|
||||
int CCDraw::getHeight() const
|
||||
{
|
||||
return height;
|
||||
return std::max(0, height);
|
||||
}
|
||||
|
||||
int CCDraw::getWidth() const
|
||||
{
|
||||
return width;
|
||||
return std::max(0, width);
|
||||
}
|
||||
|
||||
void CCDraw::setDimensionsAll(const int& xpos, const int& ypos, const int& w, const int& h)
|
||||
|
Reference in New Issue
Block a user