1--TEST-- 2GH-17280 (ldap_search() fails when $attributes array has holes) 3--EXTENSIONS-- 4ldap 5--FILE-- 6<?php 7 8/* We are assuming 3333 is not connectable */ 9$ldap = ldap_connect('ldap://127.0.0.1:3333'); 10 11// Creating an array with a hole in it 12$attr = array_unique(['cn', 'uid', 'uid', 'mail']); 13var_dump(ldap_search($ldap, 'ou=people,dc=example,dc=com', 'uid=admin', $attr)); 14 15?> 16--EXPECTF-- 17Warning: ldap_search(): Search: Can't contact LDAP server in %s on line %d 18bool(false) 19