• B
    [sanitize] Reorder condition to silence bogus gcc warning · e9f9c0d8
    Behdad Esfahbod 提交于
    Was givin a dozen of:
    
    ../../src/hb-machinery.hh: In member function ‘bool AAT::ankr::sanitize(hb_sanitize_context_t*) const’:
    ../../src/hb-machinery.hh:307:23: warning: missed loop optimization, the loop counter may overflow [-Wunsafe-loop-optimizations]
         bool ok = --this->max_ops > 0 &&
                   ~~~~~~~~~~~~~~~~~~~~~~
            this->start <= p &&
            ~~~~~~~~~~~~~~~~~~~
            p <= this->end &&
            ~~~~~~~~~~~~~~~^~
            (unsigned int) (this->end - p) >= len;
            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
    I believe those are bogus, but this silences them and does not introduce
    logic issues I believe.
    e9f9c0d8
hb-machinery.hh 26.2 KB