1
0
Fork 0
mirror of git://git.gnupg.org/gnupg.git synced 2025-07-02 22:46:30 +02:00

common: Rename external symbols in name-value.c.

* common/name-value.c, common/name-value.h: Rename symbol prefixes
from "pkc_" to "nvc_" and from "pke_" to "nve_".  Change all callers.

Signed-off-by: Werner Koch <wk@gnupg.org>
This commit is contained in:
Werner Koch 2016-06-23 12:12:50 +02:00
parent b841a883a2
commit d74d23d860
No known key found for this signature in database
GPG key ID: E3FDFF218E45B72B
4 changed files with 158 additions and 158 deletions

View file

@ -30,43 +30,43 @@
#ifndef GNUPG_COMMON_NAME_VALUE_H
#define GNUPG_COMMON_NAME_VALUE_H
struct private_key_container;
typedef struct private_key_container *pkc_t;
struct name_value_container;
typedef struct name_value_container *nvc_t;
struct private_key_entry;
typedef struct private_key_entry *pke_t;
struct name_value_entry;
typedef struct name_value_entry *nve_t;
/* Memory management, and dealing with entries. */
/* Allocate a private key container structure. */
pkc_t pkc_new (void);
nvc_t nvc_new (void);
/* Release a private key container structure. */
void pkc_release (pkc_t pk);
void nvc_release (nvc_t pk);
/* Get the name. */
char *pke_name (pke_t pke);
char *nve_name (nve_t pke);
/* Get the value. */
char *pke_value (pke_t pke);
char *nve_value (nve_t pke);
/* Lookup and iteration. */
/* Get the first non-comment entry. */
pke_t pkc_first (pkc_t pk);
nve_t nvc_first (nvc_t pk);
/* Get the first entry with the given name. */
pke_t pkc_lookup (pkc_t pk, const char *name);
nve_t nvc_lookup (nvc_t pk, const char *name);
/* Get the next non-comment entry. */
pke_t pke_next (pke_t entry);
nve_t nve_next (nve_t entry);
/* Get the next entry with the given name. */
pke_t pke_next_value (pke_t entry, const char *name);
nve_t nve_next_value (nve_t entry, const char *name);
@ -74,25 +74,25 @@ pke_t pke_next_value (pke_t entry, const char *name);
/* Add (NAME, VALUE) to PK. If an entry with NAME already exists, it
is not updated but the new entry is appended. */
gpg_error_t pkc_add (pkc_t pk, const char *name, const char *value);
gpg_error_t nvc_add (nvc_t pk, const char *name, const char *value);
/* Add (NAME, VALUE) to PK. If an entry with NAME already exists, it
is updated with VALUE. If multiple entries with NAME exist, the
first entry is updated. */
gpg_error_t pkc_set (pkc_t pk, const char *name, const char *value);
gpg_error_t nvc_set (nvc_t pk, const char *name, const char *value);
/* Delete the given entry from PK. */
void pkc_delete (pkc_t pk, pke_t pke);
void nvc_delete (nvc_t pk, nve_t pke);
/* Private key handling. */
/* Get the private key. */
gpg_error_t pkc_get_private_key (pkc_t pk, gcry_sexp_t *retsexp);
gpg_error_t nvc_get_private_key (nvc_t pk, gcry_sexp_t *retsexp);
/* Set the private key. */
gpg_error_t pkc_set_private_key (pkc_t pk, gcry_sexp_t sexp);
gpg_error_t nvc_set_private_key (nvc_t pk, gcry_sexp_t sexp);
@ -101,9 +101,9 @@ gpg_error_t pkc_set_private_key (pkc_t pk, gcry_sexp_t sexp);
/* Parse STREAM and return a newly allocated private key container
structure in RESULT. If ERRLINEP is given, the line number the
parser was last considering is stored there. */
gpg_error_t pkc_parse (pkc_t *result, int *errlinep, estream_t stream);
gpg_error_t nvc_parse (nvc_t *result, int *errlinep, estream_t stream);
/* Write a representation of PK to STREAM. */
gpg_error_t pkc_write (pkc_t pk, estream_t stream);
gpg_error_t nvc_write (nvc_t pk, estream_t stream);
#endif /* GNUPG_COMMON_NAME_VALUE_H */