mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-09 18:31:04 +00:00
Limit the size of strings we read from RCS
This calms down Coverity which fears than an evil RCS repository would break LyX.
This commit is contained in:
parent
fe5807483d
commit
d6d412c49e
@ -170,6 +170,8 @@ void RCS::scanMaster()
|
|||||||
LYXERR(Debug::LYXVC, "LyXVC::RCS: scanMaster: " << master_);
|
LYXERR(Debug::LYXVC, "LyXVC::RCS: scanMaster: " << master_);
|
||||||
|
|
||||||
ifstream ifs(master_.toFilesystemEncoding().c_str());
|
ifstream ifs(master_.toFilesystemEncoding().c_str());
|
||||||
|
// limit the size of strings we read to avoid memory problems
|
||||||
|
ifs >> setw(65636);
|
||||||
|
|
||||||
string token;
|
string token;
|
||||||
bool read_enough = false;
|
bool read_enough = false;
|
||||||
|
Loading…
Reference in New Issue
Block a user