|
|
75e927 |
From dda57af171687d60e21e8e2620e87b25939d0c29 Mon Sep 17 00:00:00 2001
|
|
|
75e927 |
From: Nikolai Kondrashov <Nikolai.Kondrashov@redhat.com>
|
|
|
75e927 |
Date: Mon, 6 Oct 2014 17:00:25 +0300
|
|
|
75e927 |
Subject: [PATCH 1/1] dhcpclient: Load dictionary.dhcp from DICTDIR.
|
|
|
75e927 |
|
|
|
75e927 |
Load dictionary.dhcp from DICTDIR instead of RADDBDIR in dhcpclient.c,
|
|
|
75e927 |
as it is found only in the former.
|
|
|
75e927 |
|
|
|
75e927 |
This fixes the following error printed when invoking dhcpclient:
|
|
|
75e927 |
|
|
|
75e927 |
Failed reading dictionary.dhcp: dict_init: Couldn't open dictionary
|
|
|
75e927 |
"/etc/raddb/dictionary.dhcp": No such file or directory
|
|
|
75e927 |
---
|
|
|
75e927 |
src/modules/proto_dhcp/dhcpclient.c | 3 ++-
|
|
|
75e927 |
1 file changed, 2 insertions(+), 1 deletion(-)
|
|
|
75e927 |
|
|
|
75e927 |
diff --git a/src/modules/proto_dhcp/dhcpclient.c b/src/modules/proto_dhcp/dhcpclient.c
|
|
|
75e927 |
index b29b9a2..ac52ffd 100644
|
|
|
75e927 |
--- a/src/modules/proto_dhcp/dhcpclient.c
|
|
|
75e927 |
+++ b/src/modules/proto_dhcp/dhcpclient.c
|
|
|
75e927 |
@@ -264,6 +264,7 @@ int main(int argc, char **argv)
|
|
|
75e927 |
char *p;
|
|
|
75e927 |
int c;
|
|
|
75e927 |
char const *radius_dir = RADDBDIR;
|
|
|
75e927 |
+ char const *dict_dir = DICTDIR;
|
|
|
75e927 |
char const *filename = NULL;
|
|
|
75e927 |
DICT_ATTR const *da;
|
|
|
75e927 |
|
|
|
75e927 |
@@ -315,7 +316,7 @@ int main(int argc, char **argv)
|
|
|
75e927 |
*/
|
|
|
75e927 |
da = dict_attrbyname("DHCP-Message-Type");
|
|
|
75e927 |
if (!da) {
|
|
|
75e927 |
- if (dict_read(radius_dir, "dictionary.dhcp") < 0) {
|
|
|
75e927 |
+ if (dict_read(dict_dir, "dictionary.dhcp") < 0) {
|
|
|
75e927 |
fprintf(stderr, "Failed reading dictionary.dhcp: %s",
|
|
|
75e927 |
fr_strerror());
|
|
|
75e927 |
return -1;
|
|
|
75e927 |
--
|
|
|
75e927 |
2.1.1
|
|
|
75e927 |
|