summaryrefslogtreecommitdiffstats
path: root/nest
diff options
context:
space:
mode:
Diffstat (limited to 'nest')
-rw-r--r--nest/password.c8
-rw-r--r--nest/password.h1
2 files changed, 9 insertions, 0 deletions
diff --git a/nest/password.c b/nest/password.c
index 6a02028..b8acb53 100644
--- a/nest/password.c
+++ b/nest/password.c
@@ -51,3 +51,11 @@ password_strncpy(char *to, char *from, int len)
}
}
+int
+password_same(struct password_item *old, struct password_item *new)
+{
+ return ((old->from == new->from) &&
+ (old->to == new->to) &&
+ (old->passive == new->passive) &&
+ password_same(old, new));
+}
diff --git a/nest/password.h b/nest/password.h
index 119aa70..481eeb6 100644
--- a/nest/password.h
+++ b/nest/password.h
@@ -20,6 +20,7 @@ struct password_item {
extern struct password_item *last_password_item;
struct password_item *get_best_password(struct password_item *head, int flags);
+extern int password_same(struct password_item *, struct password_item *);
extern void password_strncpy(char *to, char *from, int len);