<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">2014-03-09 0:37 GMT+01:00 Bear <span dir="ltr"><<a href="mailto:bear@sonic.net" target="_blank">bear@sonic.net</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div id=":35i" class="a3s" style="overflow:hidden">Oh, that is so not the way it works.  "Unreachable code" by<br>
the sense the compiler looks for is code that cannot be reached<br>
in the course of normal control flow.  Buffer overflows can<br>
work just as well with code that *can* be reached by normal<br>
control flow, so the "Unreachable code" warning won't touch<br>
them.<br></div></blockquote><div><br></div><div>Oh, you so don't get what I meant. What is normal control flow anyway? This is not functional programming. This is about GOTO related stuff. GOTO actually sets the instruction pointer, go figure!</div>

<div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div id=":35i" class="a3s" style="overflow:hidden">
On the other hand, using a language with boundary checking<br>
on parameters and variables (which is most modern languages,<br>
even modern compiled languages) is a fine way to disallow<br>
buffer overflow bugs completely.</div></blockquote></div><div class="gmail_extra"><br></div>Talk to the hordes of angry C(++) programmers about that. Fact is that a pointer is a very powerful and convenient way to deal with mass memory manipulation. Fact also is that we are rarely making memory manipulators, frequently API intermediaries. </div>

<div class="gmail_extra"><br></div><div class="gmail_extra">I have to say it doesn't always get much easier with higher level languages. Transparent (iow: unclear if I am using them) references cause a many great bug.</div>

<div class="gmail_extra"><br></div></div>