VirtualBox

Changeset 23845 in vbox for trunk/src/VBox/Additions/common


Ignore:
Timestamp:
Oct 19, 2009 8:49:10 AM (15 years ago)
Author:
vboxsync
Message:

VBoxClient/VBoxTray/VBgl: Reverted last check-ins to redo D-BUS movement.

Location:
trunk/src/VBox/Additions/common/VBoxGuestLib
Files:
1 deleted
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/common/VBoxGuestLib/Makefile.kmk

    r23839 r23845  
    8686        VBoxGuestR3LibDaemonize.cpp \
    8787        VBoxGuestR3LibGR.cpp \
    88         $(if $(VBOX_WITH_GUEST_PROPS), \
    89                 VBoxGuestR3LibGuestProp.cpp \
    90                 VBoxGuestR3LibHostVersion.cpp,) \
     88        $(if $(VBOX_WITH_GUEST_PROPS),VBoxGuestR3LibGuestProp.cpp,) \
    9189        VBoxGuestR3LibMouse.cpp \
    9290        VBoxGuestR3LibMisc.cpp \
     
    9896        VBoxGuestR3Lib.cpp \
    9997        VBoxGuestR3LibGR.cpp \
    100         $(if $(VBOX_WITH_GUEST_PROPS), \
    101                 VBoxGuestR3LibGuestProp.cpp \
    102                 VBoxGuestR3LibHostVersion.cpp,) \
     98        $(if $(VBOX_WITH_GUEST_PROPS),VBoxGuestR3LibGuestProp.cpp,) \
    10399        VBoxGuestR3LibMisc.cpp \
    104100        VBoxGuestR3LibTime.cpp
  • trunk/src/VBox/Additions/common/VBoxGuestLib/VBoxGuestR3LibMisc.cpp

    r23843 r23845  
    2626#include <iprt/mem.h>
    2727#include <VBox/log.h>
     28
    2829#include "VBGLR3Internal.h"
    2930
     
    193194}
    194195
    195 
    196 /** @todo Docs */
    197 VBGLR3DECL(int) VbglR3GetAdditionsVersion(char **ppszVer, char **ppszRev)
    198 {
    199     int rc;
    200 #ifdef RT_OS_WINDOWS
    201     HKEY hKey;
    202     LONG r;
    203 
    204     /* Check the new path first. */
    205     r = RegOpenKeyEx(HKEY_LOCAL_MACHINE, "SOFTWARE\\Sun\\VirtualBox Guest Additions", 0, KEY_READ, &hKey);
    206 # ifdef RT_ARCH_AMD64
    207     if (r != ERROR_SUCCESS)
    208     {
    209         /* Check Wow6432Node (for new entries). */
    210         r = RegOpenKeyEx(HKEY_LOCAL_MACHINE, "SOFTWARE\\Wow6432Node\\Sun\\VirtualBox Guest Additions", 0, KEY_READ, &hKey);
    211     }
    212 # endif
    213 
    214     /* Still no luck? Then try the old xVM paths ... */
    215     if (FAILED(r))
    216     {
    217         r = RegOpenKeyEx(HKEY_LOCAL_MACHINE, "SOFTWARE\\Sun\\xVM VirtualBox Guest Additions", 0, KEY_READ, &hKey);
    218 # ifdef RT_ARCH_AMD64
    219         if (r != ERROR_SUCCESS)
    220         {
    221             /* Check Wow6432Node (for new entries). */
    222             r = RegOpenKeyEx(HKEY_LOCAL_MACHINE, "SOFTWARE\\Wow6432Node\\Sun\\xVM VirtualBox Guest Additions", 0, KEY_READ, &hKey);
    223         }
    224 # endif
    225     }
    226 
    227     /* Did we get something worth looking at? */
    228     if (SUCCEEDED(r))
    229     {
    230         /* Version. */
    231         DWORD dwType;
    232         DWORD dwSize = 32;
    233         char *pszVer = (char*)RTMemAlloc(dwSize);
    234         if (pszVer)
    235         {
    236             if (ERROR_SUCCESS == RegQueryValueEx(hKey, "Version", NULL, &dwType, (BYTE*)(LPCTSTR)pszVer, &dwSize))
    237                 *ppszVer = pszVer;
    238         }
    239         /* Revision. */
    240         if (ppszRev)
    241         {
    242             dwSize = 32;
    243             char *pszRev = (char*)RTMemAlloc(dwSize);
    244             if (ERROR_SUCCESS == RegQueryValueEx(hKey, "Revision", NULL, &dwType, (BYTE*)(LPCTSTR)pszRev, &dwSize))
    245                 *ppszRev = pszRev;
    246         }
    247     }
    248     rc = RTErrConvertFromWin32(r);
    249 
    250     if (NULL != hKey)
    251         RegCloseKey(hKey);
    252 #else
    253     rc = VERR_NOT_IMPLEMENTED;
    254 #endif /* RT_OS_WINDOWS */
    255     return rc;
    256 }
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