diff options
author | Don Kjer <don@lindenlab.com> | 2007-07-20 20:38:05 +0000 |
---|---|---|
committer | Don Kjer <don@lindenlab.com> | 2007-07-20 20:38:05 +0000 |
commit | d373dcc7cbed5fdea72c6b71a5594e4e85549b43 (patch) | |
tree | 140e20f48db5dc4d7842f05ef2c24ef9e6fc3238 /indra/llinventory/llinventory.cpp | |
parent | c78f99b0b3b4b9ac99a69b63315e821d89a89a3b (diff) |
svn merge -r 64548:64837 svn+ssh://svn/svn/linden/branches/maintenance into release
* WARNING *: maintenance r64837 is not the last rev to use in the next merge. use r65269
Diffstat (limited to 'indra/llinventory/llinventory.cpp')
-rw-r--r-- | indra/llinventory/llinventory.cpp | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/indra/llinventory/llinventory.cpp b/indra/llinventory/llinventory.cpp index 36b7ab0680..60c1ade38f 100644 --- a/indra/llinventory/llinventory.cpp +++ b/indra/llinventory/llinventory.cpp @@ -515,7 +515,11 @@ BOOL LLInventoryItem::importFile(FILE* fp) mAssetUUID.setNull(); while(success && (!feof(fp))) { - fgets(buffer, MAX_STRING, fp); + if (fgets(buffer, MAX_STRING, fp) == NULL) + { + buffer[0] = '\0'; + } + sscanf(buffer, " %254s %254s", keyword, valuestr); /* Flawfinder: ignore */ if(0 == strcmp("{",keyword)) { @@ -1371,7 +1375,11 @@ BOOL LLInventoryCategory::importFile(FILE* fp) valuestr[0] = '\0'; while(!feof(fp)) { - fgets(buffer, MAX_STRING, fp); + if (fgets(buffer, MAX_STRING, fp) == NULL) + { + buffer[0] = '\0'; + } + sscanf( /* Flawfinder: ignore */ buffer, " %254s %254s", |