S
sandeep
We often read that an undefined behavior can make nosal demons appear or
reformat your hard disk. I would like to see the ISO Standard address
this problem by speaking of "undefined but reasonable" behavior.
Reasonable would mean effects are restricted to the relevant subsystem.
For example, an undefined behavior in the memory subsystem could corrupt
the value of a variable or raise a signal or abort the program, but it
cannot affect disk files.
An undefined behavior in the file subsystem could corrupt any open file
but not reformat the whole disk or send data through a network connection.
Thanks for your attention.
reformat your hard disk. I would like to see the ISO Standard address
this problem by speaking of "undefined but reasonable" behavior.
Reasonable would mean effects are restricted to the relevant subsystem.
For example, an undefined behavior in the memory subsystem could corrupt
the value of a variable or raise a signal or abort the program, but it
cannot affect disk files.
An undefined behavior in the file subsystem could corrupt any open file
but not reformat the whole disk or send data through a network connection.
Thanks for your attention.