<html>
    <head>
      <base href="https://bugs.freedesktop.org/" />
    </head>
    <body>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW --- - Misuse of setjmp in DCTStream"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=63067#c5">Comment # 5</a>
              on <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW --- - Misuse of setjmp in DCTStream"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=63067">bug 63067</a>
              from <span class="vcard"><a class="email" href="mailto:rodrigorivascosta@gmail.com" title="rodrigo <rodrigorivascosta@gmail.com>"> <span class="fn">rodrigo</span></a>
</span></b>
        <pre>(In reply to <a href="show_bug.cgi?id=63067#c4">comment #4</a>)
<span class="quote">> (In reply to <a href="show_bug.cgi?id=63067#c0">comment #0</a>)
> >     if (!setjmp(err.setjmp_buffer) && jpeg_read_header(&cinfo, TRUE) !=
> > JPEG_SUSPENDED)

> This is NOT a iteration statement, iteration statements are "for", "while"
> and similar!</span >
No, it is a *selection statement*. The other one is 'switch'. If it weren't it
would be even a worst case, because the 'setjmp' specification enumerates the
places where it is allowed to be used, not where it is forbidden.

<span class="quote">> Okay, okay, the order of execution of an if condition is undefined in C/C++.</span >

No, that's not the problem. The order of evaluation of an expression is
unspecified, except where otherwise indicated. But the && operator does insert
a sequence point, so the left part is always evaluated before the right one.
The problem is not the order of evaluation but that 'setjmp' is not allowed to
be used here.

<span class="quote">> But if we are puristic: Yes, it should be in that way!</span >

I agree that I'm being puristic, but the change costs nothing and may avoid
nasty surprises, particularly in weird architectures. And nasty looks from the
pedantics...</pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>