3xccc
Re:
on Saturday September 25, 2021 @12:10PM (#28654210)
Thanks, I was looking for someone pointing out 1). I thought I miss something.
Re:Parsing can become accidentally quadratic because of sscanf
on Monday March 01, 2021 @03:28PM (#26307960)
What about parsing an unknown number of at-most-4-digits integers from a string (being careful, as you exemplified)? Isn’t that a reasonable use of sscanf?
Do I need a full fledged parser for that? No. Does it have to traverse the whole string every time? No, because I’m being very clear about the maximum length of the thing I’m trying to parse.
You cannot not conclude that it’s a bug.