Am Donnerstag, den 19.06.2008, 12:52 -0700 schrieb Zac Brown:
> - Because these tests are mutually exclusive, a single goto label suffices 
> for 
> breaking the loop.

As written, your tests are not mutually exclusive. It could happen that
flags has IS_TEXT_UNICODE_CONTROLS and IS_TEXT_UNICODE_REVERSE_CONTROLS,
set and out_flags contains IS_TEXT_UNICODE_REVERSE_SIGNATURE. (If the
caller doesn't provide flags, both flags are set, in fact!) In that
case, both conditions of your if statements are true.

I don't know whether that means that you need two goto targets or that
your logic should be changed, but I suspect the latter. If you test for
reversed control characters only I a reversed BOM was found, you should
not test for non-reversed control characters if a reversed BOM was
found, according to my intuition.

Regards,
  Michael Karcher



Reply via email to