X-Git-Url: https://git.sommitrealweird.co.uk/onak.git/blobdiff_plain/e02c731dfbb288c736f2cd09a9b6df0507c59ddd..e3ee7975fc8f8b343390272663b8c644030b17c1:/armor.c?ds=sidebyside diff --git a/armor.c b/armor.c index 9f5c19a..343f9d6 100644 --- a/armor.c +++ b/armor.c @@ -303,9 +303,9 @@ int armor_openpgp_stream(int (*putchar_func)(void *ctx, size_t count, /* * Print armor header */ - putchar_func(ctx, sizeof("-----BEGIN PGP PUBLIC KEY BLOCK-----\n"), + putchar_func(ctx, sizeof("-----BEGIN PGP PUBLIC KEY BLOCK-----\n") - 1, (unsigned char *) "-----BEGIN PGP PUBLIC KEY BLOCK-----\n"); - putchar_func(ctx, sizeof("Version: onak " VERSION "\n\n"), + putchar_func(ctx, sizeof("Version: onak " VERSION "\n\n") - 1, (unsigned char *) "Version: onak " VERSION "\n\n"); armor_init(&armor_ctx); @@ -317,7 +317,7 @@ int armor_openpgp_stream(int (*putchar_func)(void *ctx, size_t count, /* * Print armor footer */ - putchar_func(ctx, sizeof("-----END PGP PUBLIC KEY BLOCK-----\n"), + putchar_func(ctx, sizeof("-----END PGP PUBLIC KEY BLOCK-----\n") - 1, (unsigned char *) "-----END PGP PUBLIC KEY BLOCK-----\n"); return 0;