commit 77e9241884ebb0cb48f6038baf35cafa02952a51 parent a92ed5dba1cf5168b8b7db759641bed54e7751bd Author: z3bra <willyatmailoodotorg> Date: Sun May 15 19:30:10 +12000 Use strlen() rather than sizeof() Diffstat:
sick.c | | | 4 | ++-- |
diff --git a/sick.c b/sick.c @@ -132,7 +132,7 @@ sign(FILE *fp, FILE *key) free(msg); /* .. followed by the signature delimiter .. */ - fwrite(SIGBEGIN, 1, sizeof(SIGBEGIN), stdout); + fwrite(SIGBEGIN, 1, strlen(SIGBEGIN), stdout); /* .. then the base64 encoded signature .. */ len = base64_encode(&base64, sig, 64); @@ -140,7 +140,7 @@ sign(FILE *fp, FILE *key) free(base64); /* .. and the final signature delimiter! */ - fwrite(SIGEND, 1, sizeof(SIGEND), stdout); + fwrite(SIGEND, 1, strlen(SIGEND), stdout); return 0; }