Lines Matching refs:clid
145 if ((config = find_config(daemon->dhcp_conf, NULL, lease->clid, lease->clid_len, in lease_update_from_configs()
188 if (lease->clid && lease->clid_len != 0) { in lease_update_file()
189 for (i = 0; i < lease->clid_len - 1; i++) ourprintf(&err, "%.2x:", lease->clid[i]); in lease_update_file()
190 ourprintf(&err, "%.2x\n", lease->clid[i]); in lease_update_file()
258 unsigned char* clid, int clid_len) { in lease_find_by_client() argument
261 if (clid) in lease_find_by_client()
263 if (lease->clid && clid_len == lease->clid_len && in lease_find_by_client()
264 memcmp(clid, lease->clid, clid_len) == 0) in lease_find_by_client()
268 if ((!lease->clid || !clid) && hw_len != 0 && lease->hwaddr_len == hw_len && in lease_find_by_client()
329 void lease_set_hwaddr(struct dhcp_lease* lease, unsigned char* hwaddr, unsigned char* clid, in lease_set_hwaddr() argument
342 if (clid_len != 0 && clid) { in lease_set_hwaddr()
343 if (!lease->clid) lease->clid_len = 0; in lease_set_hwaddr()
347 free(lease->clid); in lease_set_hwaddr()
348 if (!(lease->clid = whine_malloc(clid_len))) return; in lease_set_hwaddr()
349 } else if (memcmp(lease->clid, clid, clid_len) != 0) in lease_set_hwaddr()
353 memcpy(lease->clid, clid, clid_len); in lease_set_hwaddr()
476 free(lease->clid); in do_script_run()