openbmc/build/tmp/deploy/sdk/witherspoon-2019-08-08/sysroots/armv6-openbmc-linux-gnueabi/usr/src/debug/nss-pam-ldapd/0.9.8-r0/nss-pam-ldapd-0.9.8/nslcd/ether.c
static int mkfilter_ether_byname(const char* name, char* buffer, size_t buflen)
{
    char safename[BUFLEN_HOSTNAME];
    /* escape attribute */
    if (myldap_escape(name, safename, sizeof(safename)))
    {
        log_log(LOG_ERR, "mkfilter_ether_byname(): safename buffer too small");
        return -1;
    }
    /* build filter */
    return mysnprintf(buffer, buflen, "(&%s(%s=%s))", ether_filter,
                      attmap_ether_cn, safename);
}
/* create a search filter for searching an ethernet address
   by name, return -1 on errors */
create a search filter for searching an ethernet address
by name, return -1 on errors
create a search filter for searching an ethernet address by name return - 1 on errors
static int mkfilter_ether_byname(const char* name, char* buffer, size_t buflen)
{
    char safename[BUFLEN_HOSTNAME];
    if (myldap_escape(name, safename, sizeof(safename)))
    {
        log_log(LOG_ERR, "mkfilter_ether_byname(): safename buffer too small");
        return -1;
    }
    return mysnprintf(buffer, buflen, "(&%s(%s=%s))", ether_filter,
                      attmap_ether_cn, safename);
}
static int mkfilter_ether_byname ( const char * name , char * buffer , size_t buflen ) { char safename [ BUFLEN_HOSTNAME ] ; if ( myldap_escape ( name , safename , sizeof ( safename ) ) ) { log_log ( LOG_ERR , " " ) ; return -1 ; } return mysnprintf ( buffer , buflen , " " , ether_filter , attmap_ether_cn , safename ) ; }
create a search filter for searching an ethernet address
by name, return -1 on errors
create a search filter for searching an ethernet address by name return - 1 on errors
/* escape attribute */ /* build filter */