summaryrefslogtreecommitdiffstats
path: root/ldapaddressbook/abookfind.c
blob: 48c1007fd16f6b2b99c7ee358b9fbc8308eb9a23 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
/*
** Copyright 2006, Double Precision Inc.
**
** See COPYING for distribution information.
*/

#include	"config.h"
#include	"ldapaddressbook.h"

#include	<stdio.h>
#include	<string.h>
#include	<stdlib.h>

const struct ldapabook *ldapabook_find(const struct ldapabook *l,
					const char *n)
{
	while (l)
	{
		if (strcmp(l->name, n) == 0)	return (l);

		l=l->next;
	}
	return (0);
}