]> git.ozlabs.org Git - ccan/commitdiff
base64: correct linkage of base64_maps_rfc4648
authorPeter Barker <pb-ccan@barker.dropbear.id.au>
Thu, 18 Feb 2016 05:38:54 +0000 (16:38 +1100)
committerPeter Barker <pb-ccan@barker.dropbear.id.au>
Mon, 12 Dec 2016 10:56:19 +0000 (21:56 +1100)
Two copies of this map meant only the tests would ever work.

ccan/base64/base64.c
ccan/base64/base64.h

index af078bc76ef5d6535b48ed15fb70e07f5f454bfa..a216f4781a504207097a01aacb937e6625d5f855 100644 (file)
@@ -209,7 +209,7 @@ ssize_t base64_decode_using_maps(const base64_maps_t *maps,
 /**
  * base64_maps_rfc4648 - pregenerated maps struct for rfc4648
  */
-static const base64_maps_t base64_maps_rfc4648 = {
+const base64_maps_t base64_maps_rfc4648 = {
   "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",
 
   "\xff\xff\xff\xff\xff" /* 0 */                                       \
index 283c6e441f36ede0028f97e366dffe7229241bcd..405dc63fd44531d9bcfb55064ad3a0196f68f0dc 100644 (file)
@@ -122,7 +122,7 @@ int base64_decode_tail_using_maps(const base64_maps_t *maps, char *dest,
 
 /* the rfc4648 functions: */
 
-static const base64_maps_t base64_maps_rfc4648;
+extern const base64_maps_t base64_maps_rfc4648;
 
 /**
  * base64_encode - Encode a buffer into base64 according to rfc4648