VirtualBox

Changeset 65811 in vbox for trunk


Ignore:
Timestamp:
Feb 20, 2017 12:16:20 PM (8 years ago)
Author:
vboxsync
Message:

RTCString::equals(): don't call memcmp() with a zero length

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/iprt/cpp/ministring.h

    r62474 r65811  
    624624    {
    625625        return rThat.length() == length()
    626             && memcmp(rThat.m_psz, m_psz, length()) == 0;
     626            && (   length() == 0
     627                || memcmp(rThat.m_psz, m_psz, length()) == 0);
    627628    }
    628629
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette