Skip to content

Commit

Permalink
Additional sscanf found and code update.
Browse files Browse the repository at this point in the history
  • Loading branch information
vidanovic committed Oct 16, 2024
1 parent e4511b1 commit 631fb1e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/thmxParser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,11 @@ namespace thmxParser
float temperature = std::stof(str);
str = getAttribute(bcondNode, "RGBColor");
unsigned int red, green, blue;
#ifdef _MSC_VER
sscanf_s(str.c_str(), "0x%02x%02x%02x", &red, &green, &blue);
#else
std::sscanf(str.c_str(), "0x%02x%02x%02x", &red, &green, &blue);
#endif
ColorRGB color{red, green, blue};

str = getAttribute(bcondNode, "Tr");
Expand Down

0 comments on commit 631fb1e

Please sign in to comment.