mirror of
https://bitbucket.org/smil3y/katie.git
synced 2025-02-24 10:52:56 +00:00
pass the size of string to QString::fromLatin1() constructor in QColor::name()
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
parent
5c4561a939
commit
8f48847be2
1 changed files with 1 additions and 1 deletions
|
@ -645,7 +645,7 @@ QString QColor::name() const
|
|||
{
|
||||
QSTACKARRAY(char, snprintfbuf, 8);
|
||||
::snprintf(snprintfbuf, sizeof(snprintfbuf), "#%02x%02x%02x", red(), green(), blue());
|
||||
return QString::fromLatin1(snprintfbuf);
|
||||
return QString::fromLatin1(snprintfbuf, sizeof(snprintfbuf) - 1);
|
||||
}
|
||||
|
||||
/*!
|
||||
|
|
Loading…
Add table
Reference in a new issue