mirror of
https://github.com/Kitware/CMake.git
synced 2026-04-24 07:08:38 -05:00
Source: Replace most calls to sprintf with snprintf
This commit is contained in:
@@ -136,7 +136,8 @@ void cmGeneratedFileStreamBase::Open(std::string const& name)
|
||||
this->TempName += this->TempExt;
|
||||
} else {
|
||||
char buf[64];
|
||||
sprintf(buf, "tmp%05x", cmSystemTools::RandomSeed() & 0xFFFFF);
|
||||
snprintf(buf, sizeof(buf), "tmp%05x",
|
||||
cmSystemTools::RandomSeed() & 0xFFFFF);
|
||||
this->TempName += buf;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user