aboutsummaryrefslogtreecommitdiffstats
path: root/set.c
diff options
context:
space:
mode:
authorSven Moritz Hallberg <sm@khjk.org>2008-02-12 01:01:35 +0100
committerSven Moritz Hallberg <sm@khjk.org>2008-02-12 01:01:35 +0100
commite2b15bb7ebd347dd044167575068ef87ffd9301c (patch)
tree5ff386cd06c3d282b39e0e8f8792f956222b31a6 /set.c
parent5f4eedefd2a444c213f65283a3d942d6287e6ea2 (diff)
- add global policy setting
- add copyright and author notices to otr.h and otr.c
Diffstat (limited to 'set.c')
-rw-r--r--set.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/set.c b/set.c
index 0e9ae5dc..c65953f2 100644
--- a/set.c
+++ b/set.c
@@ -368,3 +368,17 @@ char *set_eval_charset( set_t *set, char *value )
g_iconv_close( cd );
return value;
}
+
+/* possible values: never, opportunistic, manual, always */
+char *set_eval_otr_policy( set_t *set, char *value )
+{
+ if ( !strcmp(value, "never") )
+ return value;
+ if ( !strcmp(value, "opportunistic") )
+ return value;
+ if ( !strcmp(value, "manual") )
+ return value;
+ if ( !strcmp(value, "always") )
+ return value;
+ return NULL;
+}