Jump to main content

##

# TCPIP_DHCPS_LeaseEntryGet Function

## C

    TCPIP_DHCPS_LEASE_HANDLE TCPIP_DHCPS_LeaseEntryGet(
        TCPIP_NET_HANDLE netH,
        TCPIP_DHCPS_LEASE_ENTRY* pLeaseEntry,
        TCPIP_DHCPS_LEASE_HANDLE leaseHandle
    );

## Description

This function returns a lease entry for the TCPIP_DHCPS_LEASE_HANDLE. if the lease entry is not present for that TCPIP_DHCPS_LEASE_HANDLE, then it will return the next valid lease entry.

## Preconditions

The DHCP server module must be initialized.

## Parameters

Parameters | Description
--- | ---
netH | Lease entry for this interface.
pLeaseEntry | Client lease entry details.
leaseHandle | Lease index.

## Returns

- non-zero TCPIP_DHCPS_LEASE_HANDLE - To be used in the subsequent calls.
- 0 - If end of list or wrong interface, or DHCP server is not running on that interface.