VirtualBox

Changeset 45652 in vbox for trunk/src/VBox/Devices


Ignore:
Timestamp:
Apr 19, 2013 6:16:28 PM (12 years ago)
Author:
vboxsync
Message:

slirp/tftp.c: better error message if option negotiation fails (often because the requested file doesn't exist), especially in combination with Intel PXE, plus cleanups

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Network/slirp/tftp.c

    r43876 r45652  
    434434    if (RT_FAILURE(rc))
    435435    {
    436         LogFlowFuncLeave();
     436        LogFlowFuncLeaveRC(rc);
    437437        return rc;
    438438    }
     
    442442    if (RT_FAILURE(rc))
    443443    {
    444         LogFlowFuncLeave();
     444        LogFlowFuncLeaveRC(rc);
    445445        return rc;
    446446    }
     
    448448    if (pTftpSession->OptionTSize.fRequested)
    449449    {
    450        pTftpSession->OptionTSize.u64Value = cbSessionFile;
     450        pTftpSession->OptionTSize.u64Value = cbSessionFile;
    451451    }
    452452    if (   !pTftpSession->OptionBlkSize.u64Value
     
    570570    if (RT_FAILURE(rc))
    571571    {
    572         tftpSendError(pData, pTftpSession, 2, "Internal Error (blksize evaluation)", pcTftpIpHeaderRecv);
     572        tftpSendError(pData, pTftpSession, 2, "Option negotiation failure (file not found or inaccessible?)", pcTftpIpHeaderRecv);
    573573        LogFlowFuncLeave();
    574574        return -1;
     
    578578    if (!m)
    579579        return -1;
    580 
    581 
    582580
    583581    m->m_data += if_maxlinkhdr;
     
    757755        return;
    758756
    759     AssertReturnVoid(tftpSendData(pData,
    760                                     pTftpSession,
    761                                     RT_N2H_U16(pTftpIpHeader->Core.u16TftpOpCode), pTftpIpHeader) == 0);
     757    if (tftpSendData(pData, pTftpSession,
     758                     RT_N2H_U16(pTftpIpHeader->Core.u16TftpOpCode),
     759                     pTftpIpHeader))
     760        LogRel(("NAT TFTP: failure\n"));
    762761}
    763762
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