summaryrefslogtreecommitdiff
path: root/src/lib/encoding/kvline.h
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2019-04-05 15:29:37 -0400
committerNick Mathewson <nickm@torproject.org>2019-04-25 14:13:03 -0400
commit73df91bbb55498b05faae16b49ab49545fdffa8f (patch)
treef924a1baaef554e381d50d8fe92529dd5bee0896 /src/lib/encoding/kvline.h
parent01b07c548b93bcc58adac612a02c69dcb4b63b28 (diff)
downloadtor-73df91bbb55498b05faae16b49ab49545fdffa8f.tar.gz
tor-73df91bbb55498b05faae16b49ab49545fdffa8f.zip
kvline: handle empty alues as well as empty keys
The two options are mutually exclusive, since otherwise an entry like "Foo" would be ambiguous. We want to have the ability to treat entries like this as keys, though, since some controller commands interpret them as flags.
Diffstat (limited to 'src/lib/encoding/kvline.h')
-rw-r--r--src/lib/encoding/kvline.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/lib/encoding/kvline.h b/src/lib/encoding/kvline.h
index 4eed30a223..6740f81d54 100644
--- a/src/lib/encoding/kvline.h
+++ b/src/lib/encoding/kvline.h
@@ -17,6 +17,7 @@ struct config_line_t;
#define KV_QUOTED (1u<<0)
#define KV_OMIT_KEYS (1u<<1)
+#define KV_OMIT_VALS (1u<<2)
struct config_line_t *kvline_parse(const char *line, unsigned flags);
char *kvline_encode(const struct config_line_t *line, unsigned flags);