[Pkg-gnupg-commit] [gnupg2] 40/160: common: Rename private-keys.c to name-value.c

Daniel Kahn Gillmor dkg at fifthhorseman.net
Fri Jul 15 09:36:34 UTC 2016


This is an automated email from the git hooks/post-receive script.

dkg pushed a commit to branch upstream
in repository gnupg2.

commit b841a883a2a66807aa427e65d49067584bedfbe2
Author: Werner Koch <wk at gnupg.org>
Date:   Thu Jun 23 11:55:46 2016 +0200

    common: Rename private-keys.c to name-value.c
    
    * common/private-keys.c: Rename to name-value.c.
    * common/private-keys.h: Rename to name-value.h.  Chage all users.
    * common/t-private-keys.c: Rename to t-name-value.c.
    * common/Makefile.am: Adjust accordingly.
    --
    
    The module is cool enough to be used for other purposes as well.  Thus
    we better change the name.
    
    Signed-off-by: Werner Koch <wk at gnupg.org>
---
 agent/findkey.c                             | 2 +-
 common/Makefile.am                          | 6 +++---
 common/{private-keys.c => name-value.c}     | 9 +++++++--
 common/{private-keys.h => name-value.h}     | 8 ++++----
 common/{t-private-keys.c => t-name-value.c} | 4 ++--
 5 files changed, 17 insertions(+), 12 deletions(-)

diff --git a/agent/findkey.c b/agent/findkey.c
index d3780b9..b221510 100644
--- a/agent/findkey.c
+++ b/agent/findkey.c
@@ -35,7 +35,7 @@
 #include "agent.h"
 #include "i18n.h"
 #include "../common/ssh-utils.h"
-#include "../common/private-keys.h"
+#include "../common/name-value.h"
 
 #ifndef O_BINARY
 #define O_BINARY 0
diff --git a/common/Makefile.am b/common/Makefile.am
index 884c966..2451689 100644
--- a/common/Makefile.am
+++ b/common/Makefile.am
@@ -91,7 +91,7 @@ common_sources = \
 	call-gpg.c call-gpg.h \
 	exectool.c exectool.h \
 	server-help.c server-help.h \
-	private-keys.c private-keys.h
+	name-value.c name-value.h
 
 if HAVE_W32_SYSTEM
 common_sources += w32-reg.c w32-afunix.c w32-afunix.h
@@ -157,7 +157,7 @@ module_tests = t-stringhelp t-timestuff \
                t-convert t-percent t-gettime t-sysutils t-sexputil \
 	       t-session-env t-openpgp-oid t-ssh-utils \
 	       t-mapstrings t-zb32 t-mbox-util t-iobuf t-strlist \
-	       t-private-keys t-ccparray
+	       t-name-value t-ccparray
 if !HAVE_W32CE_SYSTEM
 module_tests += t-exechelp
 endif
@@ -206,7 +206,7 @@ t_zb32_LDADD = $(t_common_ldadd)
 t_mbox_util_LDADD = $(t_common_ldadd)
 t_iobuf_LDADD = $(t_common_ldadd)
 t_strlist_LDADD = $(t_common_ldadd)
-t_private_keys_LDADD = $(t_common_ldadd)
+t_name_value_LDADD = $(t_common_ldadd)
 t_ccparray_LDADD = $(t_common_ldadd)
 
 # System specific test
diff --git a/common/private-keys.c b/common/name-value.c
similarity index 98%
rename from common/private-keys.c
rename to common/name-value.c
index 4cf7d22..601ddd4 100644
--- a/common/private-keys.c
+++ b/common/name-value.c
@@ -1,4 +1,4 @@
-/* private-keys.c - Parser and writer for the extended private key format.
+/* name-value.c - Parser and writer for a name-value format.
  *	Copyright (C) 2016 g10 Code GmbH
  *
  * This file is part of GnuPG.
@@ -27,16 +27,21 @@
  * along with this program; if not, see <http://www.gnu.org/licenses/>.
  */
 
+/*
+ * This module aso provides features for the extended private key
+ * format of gpg-agent.
+ */
+
 #include <config.h>
 #include <assert.h>
 #include <gcrypt.h>
 #include <gpg-error.h>
 #include <string.h>
 
-#include "private-keys.h"
 #include "mischelp.h"
 #include "strlist.h"
 #include "util.h"
+#include "name-value.h"
 
 struct private_key_container
 {
diff --git a/common/private-keys.h b/common/name-value.h
similarity index 94%
rename from common/private-keys.h
rename to common/name-value.h
index d21e94f..0a8694a 100644
--- a/common/private-keys.h
+++ b/common/name-value.h
@@ -1,4 +1,4 @@
-/* private-keys.h - Parser and writer for the extended private key format.
+/* name-value.h - Parser and writer for a name-value format.
  *	Copyright (C) 2016 g10 Code GmbH
  *
  * This file is part of GnuPG.
@@ -27,8 +27,8 @@
  * along with this program; if not, see <http://www.gnu.org/licenses/>.
  */
 
-#ifndef GNUPG_COMMON_PRIVATE_KEYS_H
-#define GNUPG_COMMON_PRIVATE_KEYS_H
+#ifndef GNUPG_COMMON_NAME_VALUE_H
+#define GNUPG_COMMON_NAME_VALUE_H
 
 struct private_key_container;
 typedef struct private_key_container *pkc_t;
@@ -106,4 +106,4 @@ gpg_error_t pkc_parse (pkc_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);
 
-#endif /* GNUPG_COMMON_PRIVATE_KEYS_H */
+#endif /* GNUPG_COMMON_NAME_VALUE_H */
diff --git a/common/t-private-keys.c b/common/t-name-value.c
similarity index 99%
rename from common/t-private-keys.c
rename to common/t-name-value.c
index 1027e70..d6cef35 100644
--- a/common/t-private-keys.c
+++ b/common/t-name-value.c
@@ -1,4 +1,4 @@
-/* t-private-keys.c - Module test for private-keys.c
+/* t-name-value.c - Module test for name-value.c
  *	Copyright (C) 2016 g10 Code GmbH
  *
  * This file is part of GnuPG.
@@ -26,7 +26,7 @@
 #include <sys/stat.h>
 
 #include "util.h"
-#include "private-keys.h"
+#include "name-value.h"
 
 static int verbose;
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-gnupg/gnupg2.git



More information about the Pkg-gnupg-commit mailing list