aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
Diffstat (limited to 'tools')
-rw-r--r--tools/ChangeLog8
-rw-r--r--tools/gpgconf-comp.c28
-rw-r--r--tools/gpgparsemail.c6
3 files changed, 13 insertions, 29 deletions
diff --git a/tools/ChangeLog b/tools/ChangeLog
index 67dcbd860..4ac20ae0b 100644
--- a/tools/ChangeLog
+++ b/tools/ChangeLog
@@ -1,3 +1,11 @@
+2006-05-23 Werner Koch <[email protected]>
+
+ * gpgparsemail.c: Include config.h if available
+ (stpcpy): Conditional include it.
+
+ * gpgconf-comp.c (hextobyte): Removed as it is now availble in
+ jnlib.
+
2005-12-20 Werner Koch <[email protected]>
* gpgconf-comp.c (gc_options_gpg): Add allow-pka-lookup.
diff --git a/tools/gpgconf-comp.c b/tools/gpgconf-comp.c
index a27da3941..2da88bc49 100644
--- a/tools/gpgconf-comp.c
+++ b/tools/gpgconf-comp.c
@@ -998,34 +998,6 @@ percent_escape (const char *src)
}
-/* Convert two hexadecimal digits from STR to the value they
- represent. Returns -1 if one of the characters is not a
- hexadecimal digit. */
-static int
-hextobyte (const char *str)
-{
- int val = 0;
- int i;
-
-#define NROFHEXDIGITS 2
- for (i = 0; i < NROFHEXDIGITS; i++)
- {
- if (*str >= '0' && *str <= '9')
- val += *str - '0';
- else if (*str >= 'A' && *str <= 'F')
- val += 10 + *str - 'A';
- else if (*str >= 'a' && *str <= 'f')
- val += 10 + *str - 'a';
- else
- return -1;
- if (i < NROFHEXDIGITS - 1)
- val *= 16;
- str++;
- }
- return val;
-}
-
-
/* Percent-Deescape special characters. The string is valid until the
next invocation of the function. */
diff --git a/tools/gpgparsemail.c b/tools/gpgparsemail.c
index da56093c3..566f5747f 100644
--- a/tools/gpgparsemail.c
+++ b/tools/gpgparsemail.c
@@ -24,6 +24,9 @@
for the content of the line. Several options are available to
scrutinize the message. S/MIME and OpenPGP support is included. */
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
#include <stdio.h>
#include <stdlib.h>
@@ -145,6 +148,7 @@ xstrdup (const char *string)
return p;
}
+#ifndef HAVE_STPCPY
static char *
stpcpy (char *a,const char *b)
{
@@ -154,7 +158,7 @@ stpcpy (char *a,const char *b)
return (char*)a;
}
-
+#endif
static int
run_gnupg (int smime, int sig_fd, int data_fd, int *close_list)