VirtualBox

Changeset 60999 in vbox for trunk/src/VBox/Main/src-all


Ignore:
Timestamp:
May 17, 2016 11:44:03 AM (9 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
107251
Message:

Main/ThreadTask: cleanups, remove unused variable and static method

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/src-all/ThreadTask.cpp

    r59454 r60999  
    44
    55/*
    6  * Copyright (C) 2015 Oracle Corporation
     6 * Copyright (C) 2015-2016 Oracle Corporation
    77 *
    88 * This file is part of VirtualBox Open Source Edition (OSE), as
     
    2626 *  pointer in all cases.
    2727 *  Possible way of usage:
    28  * 
     28 *
    2929 *  int vrc = VINF_SUCCESS;
    3030 *  HRESULT hr = S_OK;
    31  * 
     31 *
    3232 *  SomeTaskInheritedFromThreadTask* pTask = NULL;
    3333 *  try
     
    4141 *      //this function delete pTask in case of exceptions, so
    4242 *      there is no need the call of delete operator
    43  * 
     43 *
    4444 *      hr = pTask->createThread();
    4545 *  }
     
    6464    if (RT_FAILURE(vrc))
    6565    {
    66         delete this; 
     66        delete this;
    6767        return E_FAIL;
    6868    }
     
    7777/* static */ DECLCALLBACK(int) ThreadTask::taskHandler(RTTHREAD /* thread */, void *pvUser)
    7878{
    79     HRESULT rc = S_OK;
    8079    if (pvUser == NULL)
    8180        return VERR_INVALID_POINTER;
     
    9089    delete pTask;
    9190
    92     return 0;
     91    return VINF_SUCCESS;
    9392}
    94 
    95 /*static*/ HRESULT ThreadTask::setErrorStatic(HRESULT aResultCode,
    96                                     const Utf8Str &aText)
    97 {
    98     NOREF(aText);
    99     return aResultCode;
    100 }
    101 
Note: See TracChangeset for help on using the changeset viewer.

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