Make sure that we have a token when doing sscanf in llinventory.cpp and llviewerobject.cpp
Guards against opensim grids that may leave new/blank lines of sorts after their message blocks
This commit is contained in:
@@ -2903,7 +2903,7 @@ BOOL LLViewerObject::loadTaskInvFile(const std::string& filename)
|
||||
while(ifs.good())
|
||||
{
|
||||
ifs.getline(buffer, MAX_STRING);
|
||||
sscanf(buffer, " %254s", keyword); /* Flawfinder: ignore */
|
||||
if (sscanf(buffer, " %254s", keyword) < 1) continue;
|
||||
if(0 == strcmp("inv_item", keyword))
|
||||
{
|
||||
LLPointer<LLInventoryObject> inv = new LLViewerInventoryItem;
|
||||
|
||||
Reference in New Issue
Block a user