@@ -1193,24 +1193,24 @@ pyexpat.xmlparser.SetAllocTrackerMaximumAmplification
1193
1193
1194
1194
Sets the maximum amplification factor between direct input and bytes of dynamic memory allocated.
1195
1195
1196
- By default, parsers objects have a maximum amplification factor of 100.
1197
-
1198
1196
The amplification factor is calculated as "allocated / direct" while parsing,
1199
1197
where "direct" is the number of bytes read from the primary document in parsing
1200
1198
and "allocated" is the number of bytes of dynamic memory allocated in the parser
1201
1199
hierarchy.
1202
1200
1203
1201
The 'max_factor' value must be a non-NaN floating point value greater than
1204
- or equal to 1.0. Amplifications factors greater than 100 can been observed
1205
- near the start of parsing even with benign files in practice. As such, the
1206
- activation threshold should be carefully chosen to avoid false positives.
1202
+ or equal to 1.0. Amplification factors greater than 100.0 can be observed
1203
+ near the start of parsing even with benign files in practice. In particular,
1204
+ the activation threshold should be carefully chosen to avoid false positives.
1205
+
1206
+ By default, parser objects have a maximum amplification factor of 100.0.
1207
1207
[clinic start generated code]*/
1208
1208
1209
1209
static PyObject *
1210
1210
pyexpat_xmlparser_SetAllocTrackerMaximumAmplification_impl (xmlparseobject * self ,
1211
1211
PyTypeObject * cls ,
1212
1212
float max_factor )
1213
- /*[clinic end generated code: output=6e44bd48c9b112a0 input=23ca8b8f7de04462 ]*/
1213
+ /*[clinic end generated code: output=6e44bd48c9b112a0 input=e4f48064c79bf323 ]*/
1214
1214
{
1215
1215
#if XML_COMBINED_VERSION >= 20702
1216
1216
assert (self -> itself != NULL );
@@ -1250,14 +1250,14 @@ pyexpat.xmlparser.SetAllocTrackerActivationThreshold
1250
1250
1251
1251
Sets the number of allocated bytes of dynamic memory needed to activate protection against disproportionate use of RAM.
1252
1252
1253
- By default, parsers objects have an allocation activation threshold of 64 MiB.
1253
+ By default, parser objects have an allocation activation threshold of 64 MiB.
1254
1254
[clinic start generated code]*/
1255
1255
1256
1256
static PyObject *
1257
1257
pyexpat_xmlparser_SetAllocTrackerActivationThreshold_impl (xmlparseobject * self ,
1258
1258
PyTypeObject * cls ,
1259
1259
unsigned long long threshold )
1260
- /*[clinic end generated code: output=bed7e93207ba08c5 input=8453509a137a47c0 ]*/
1260
+ /*[clinic end generated code: output=bed7e93207ba08c5 input=54182cd71ad69978 ]*/
1261
1261
{
1262
1262
#if XML_COMBINED_VERSION >= 20702
1263
1263
assert (self -> itself != NULL );
0 commit comments