VLScgSetServerLockInfo2

Syntax

int VLScgSetServerLockInfo2(VLScg_HANDLE iHandle, codeT *codeP, char *lockCode, int num);
Argument Description
iHandle

The instance handle for this library.

codeP

The pointer to the codeT struct.

lockCode

The locking code to be checked and set. Locking code should be an 8-character hex string (32-bit numeric locking code), optionally preceded by “0x.”

num

Position in server_lock_info2 where lockCode is stored starting from 0 to num_servers-1 where num_servers is set using VLScgSetNumServers.

server_lock_info2 is an array of 11 elements storing the secondary locking codes for 11 servers.

Description

Installs the value of lockCode in the code structure field server_lock_info2[num] to set the secondary locking code.

Returns

The status code VLScg_SUCCESS is returned if successful. Otherwise, it will return the following error codes:

Error Code Description

VLScg_EXCEEDS_MAX_VALUE

If value of num exceeds the maximum number of license managers. The value set using the API VLScgSetNumServers.

VLScg_LESS_THAN_MIN_VALUE

If value of num is lower than minimum (5).

VLScg_INVALID_CHKSUM

Error occurred either due to invalid lock code or checksum validation failure.

For the complete list of the error codes, refer to License Generation and Revocation Error Codes .