From 3bab48000c4e61104b30ac379806cad3e1376ea6 Mon Sep 17 00:00:00 2001 From: Daiki Ueno Date: Wed, 25 Jan 2017 15:54:40 +0100 Subject: common: Add path encoding functions This adds p11_path_{encode,decode}(), following the escaping rule described in: https://dbus.freedesktop.org/doc/dbus-specification.html#addresses Although they are merely a wrapper around p11_url_{decode,encode}(), having dedicated functions hides the implementation details. --- common/path.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'common/path.h') diff --git a/common/path.h b/common/path.h index 0b19a5d..243c14f 100644 --- a/common/path.h +++ b/common/path.h @@ -66,4 +66,8 @@ bool p11_path_prefix (const char *string, void p11_path_canon (char *name); +char * p11_path_encode (const char *path); + +char * p11_path_decode (const char *path); + #endif /* P11_PATH_H__ */ -- cgit v1.1