Sfoglia il codice sorgente

Avoid implicit function declarations.

* src/agent.h (scute_agent_get_cert): New prototype.
* src/cert-gpgsm.c: Add missing includes.
* src/debug.c: Likewise.
* src/p11-getslotinfo.c: Likewise.
* tests/t-getattribute.c: Likewise.

Signed-off-by: Justus Winter <justus@g10code.com>
Justus Winter 9 anni fa
parent
commit
280d7d079c
5 ha cambiato i file con 10 aggiunte e 0 eliminazioni
  1. 5 0
      src/agent.h
  2. 1 0
      src/cert-gpgsm.c
  3. 1 0
      src/debug.c
  4. 2 0
      src/p11-getslotinfo.c
  5. 1 0
      tests/t-getattribute.c

+ 5 - 0
src/agent.h

@@ -33,6 +33,8 @@
 #include <gpg-error.h>
 #include <stdbool.h>
 
+#include "cert.h"
+
 
 /* The information structure for a smart card.  */
 struct agent_card_info_s 
@@ -108,4 +110,7 @@ gpg_error_t scute_agent_sign (char *grip, unsigned char *data, int len,
 /* Determine if FPR is trusted.  */
 gpg_error_t scute_agent_is_trusted (char *fpr, bool *is_trusted);
 
+/* Try to get certificate for key numer NO.  */
+gpg_error_t scute_agent_get_cert (int no, struct cert *cert);
+
 #endif	/* AGENT_H */

+ 1 - 0
src/cert-gpgsm.c

@@ -40,6 +40,7 @@
 #include <gpg-error.h>
 #include <assuan.h>
 
+#include "agent.h"
 #include "cert.h"
 #include "support.h"
 #include "debug.h"

+ 1 - 0
src/debug.c

@@ -31,6 +31,7 @@
 #include <config.h>
 #endif
 
+#include <ctype.h>
 #include <stdio.h>
 #include <stdlib.h>
 

+ 2 - 0
src/p11-getslotinfo.c

@@ -31,10 +31,12 @@
 #include <config.h>
 #endif
 
+#include <stdlib.h>
 #include <string.h>
 
 #include "cryptoki.h"
 
+#include "agent.h"
 #include "locking.h"
 #include "support.h"
 #include "settings.h"

+ 1 - 0
tests/t-getattribute.c

@@ -29,6 +29,7 @@
 
 #include <stdio.h>
 #include <stdbool.h>
+#include <string.h>
 #include <ctype.h>
 
 #include "t-support.h"