We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0c7c52b commit ca4b4beCopy full SHA for ca4b4be
1 file changed
pxr/usd/sdf/crateFile.cpp
@@ -1145,6 +1145,13 @@ class CrateFile::_Reader
1145
// separate because the two modifications to 'src' must be correctly
1146
// sequenced.
1147
auto key = Read<typename Map::key_type>();
1148
+ if constexpr (SafetyOverSpeed) {
1149
+ if map.find(key) != map.end() {
1150
+ TF_RUNTIME_ERROR("Corrupt asset <%s>: Duplicate map key %s",
1151
+ crate->GetAssetPath().c_str(),
1152
+ key.GetText().c_str());
1153
+ }
1154
1155
map[key] = Read<typename Map::mapped_type>();
1156
}
1157
return map;
0 commit comments