VirtualBox

Ignore:
Timestamp:
Aug 10, 2016 3:04:27 PM (8 years ago)
Author:
vboxsync
Message:

NetworkServices: warnings

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/NetworkServices/NetLib/VBoxNetPortForwardString.cpp

    r63284 r63285  
    8383
    8484        if (cchField != 0)
    85             RTStrCopy(pszAddress, RT_MIN(cchField + 1, cbAddress), pszRaw);
     85            RTStrCopy(pszAddress, RT_MIN(cchField + 1, (size_t)cbAddress), pszRaw);
    8686        else if (!fEmptyAcceptable)
    8787            return -1;
     
    246246int netPfStrToPf(const char *pcszStrPortForward, bool fIPv6, PPORTFORWARDRULE pPfr)
    247247{
    248 /** r=bird: Redo from scratch?  This is very hard to read. */
     248/** r=bird: Redo from scratch?  This is very hard to read.  And it's going about
     249 *  things in a very complicated, potentially leaky (pszRaw) fashion. */
    249250
    250251    int  proto;
     
    286287        cbToken = pszEndOfName - pszRaw; /* don't take : into account */
    287288        /* XXX it's unacceptable to have only name entry in PF */
    288         AssertReturn(cbToken < cchRaw, VERR_INVALID_PARAMETER);
     289        AssertReturn(cbToken < (ssize_t)cchRaw, VERR_INVALID_PARAMETER);
    289290
    290291        if (   cbToken < 0
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