# Name

VixVM_GetCurrentSnapshot

# Description

    VixError
    VixVM_GetCurrentSnapshot(VixHandle vmHandle,
                             VixHandle *snapshotHandle);

This function returns the handle of the current active snapshot belonging to the virtual machine referenced by vmHandle.

# Parameters

vmHandle
  Identifies a virtual machine. Call VixVM_Open() to create a virtual machine handle.
snapshotHandle
  An output parameter that receives a handle to a snapshot.

# Return Value

VixError.

# Remarks

- This function returns the handle of the current active snapshot belonging to the virtual machine referenced by vmHandle.
- The snapshotHandle returned by this function is reference counted. The calling application is responsible for releasing the handle.
- This function is not supported when using the VIX_SERVICEPROVIDER_VMWARE_PLAYER host type.

# Side Effects

None.

# Requirements

vix.h, since VMware Workstation 6.0

# Example

    VixHandle snapshotHandle;
    VixError err;

    err = VixVM_GetCurrentSnapshot(vmHandle, &snapshotHandle);

    // remove/revert, otherwise use the snapshot

Copyright (C) 2007-2018 VMware, Inc. All rights reserved.