summaryrefslogtreecommitdiff
path: root/accel-pppd/ctrl/l2tp/dict.c
diff options
context:
space:
mode:
authorDmitry Kozlov <xeb@mail.ru>2014-11-22 08:56:40 +0300
committerDmitry Kozlov <xeb@mail.ru>2014-11-22 08:56:40 +0300
commit81ca3923a29ea9b67f7291be23b210019546aa5f (patch)
treefcebf0d426665b4f06e01168f27cd8f9ab8c50d8 /accel-pppd/ctrl/l2tp/dict.c
parent830c399cf126f6bf1e8dfa1ad919a3ce8e346c5d (diff)
downloadaccel-ppp-81ca3923a29ea9b67f7291be23b210019546aa5f.tar.gz
accel-ppp-81ca3923a29ea9b67f7291be23b210019546aa5f.zip
remove trailing whitespaces
Diffstat (limited to 'accel-pppd/ctrl/l2tp/dict.c')
-rw-r--r--accel-pppd/ctrl/l2tp/dict.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/accel-pppd/ctrl/l2tp/dict.c b/accel-pppd/ctrl/l2tp/dict.c
index f145449..b636c87 100644
--- a/accel-pppd/ctrl/l2tp/dict.c
+++ b/accel-pppd/ctrl/l2tp/dict.c
@@ -70,7 +70,7 @@ const struct l2tp_dict_value_t *l2tp_dict_find_value(const struct l2tp_dict_attr
static char *skip_word(char *ptr)
{
for(; *ptr; ptr++)
- if (*ptr == ' ' || *ptr == '\t' || *ptr == '\n')
+ if (*ptr == ' ' || *ptr == '\t' || *ptr == '\n')
break;
return ptr;
}
@@ -91,9 +91,9 @@ static int split(char *buf, char **ptr)
buf = skip_word(buf);
if (!*buf)
return i;
-
+
*buf = 0;
-
+
buf = skip_space(buf + 1);
if (!*buf)
return i;
@@ -153,12 +153,12 @@ static int dict_load(const char *fname)
} else if (!strcmp(buf, "ATTRIBUTE")) {
if (r < 3)
goto out_syntax;
-
+
attr = malloc(sizeof(*attr));
memset(attr, 0, sizeof(*attr));
list_add_tail(&attr->entry, items);
INIT_LIST_HEAD(&attr->values);
-
+
attr->name = strdup(ptr[0]);
attr->id = strtol(ptr[1], &endptr, 10);
if (*endptr != 0)
@@ -197,7 +197,7 @@ static int dict_load(const char *fname)
} else if (!strcmp(buf, "VALUE")) {
if (r != 3)
goto out_syntax;
-
+
attr = l2tp_dict_find_attr_by_name(ptr[0]);
if (!attr) {
log_emerg("l2tp:%s:%i: attribute not found\n", fname, n);