Re: [PATCH] scanf.3: Do not mention the ERANGE error

Zack Weinberg
2022-12-29T06:44:44Z

On Wed, 14 Dec 2022 06:03:07 -0500, Ian Abbott wrote:
> And would ERANGE cause scanf to return EOF in the fixed
> implementation?

In the counterfactual universe where I actually patch scanf, yes.

> That seems like it would break a lot of existing code
> (even though it is currently UB). It would probably be better to
> silently set errno to ERANGE without returning EOF

My intuition says it’s the other way around. What existing code do
you expect will break?

zw