VirtualBox

Changeset 45381 in vbox


Ignore:
Timestamp:
Apr 5, 2013 3:00:45 PM (11 years ago)
Author:
vboxsync
Message:

Runtime/http: added error code + don't make tstHttp fail if we can't connect

Location:
trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/iprt/err.h

    r44528 r45381  
    15741574/** The server did not understand the request due to bad syntax. */
    15751575#define VERR_HTTP_BAD_REQUEST                   (-887)
     1576/** Couldn't connect to the server (proxy?) */
     1577#define VERR_HTTP_COULDNT_CONNECT               (-888)
    15761578/** @} */
    15771579
  • trunk/src/VBox/Runtime/common/misc/http.cpp

    r45343 r45381  
    340340                rc = VERR_HTTP_NOT_FOUND;
    341341                break;
     342            case CURLE_COULDNT_CONNECT:
     343                rc = VERR_HTTP_COULDNT_CONNECT;
     344                break;
    342345            default:
    343346                break;
  • trunk/src/VBox/Runtime/testcase/tstHttp.cpp

    r45366 r45381  
    4242    unsigned cErrors = 0;
    4343
    44     RTR3InitExeNoArguments(RTR3INIT_FLAGS_SUPLIB);
     44    RTR3InitExeNoArguments(0);
    4545
    4646    RTHTTP hHttp;
     
    212212                       &pszBuf);
    213213
    214     if (RT_FAILURE(rc))
     214    if (   RT_FAILURE(rc)
     215        && rc != VERR_HTTP_COULDNT_CONNECT)
    215216        cErrors++;
    216217
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