aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--crypt.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/crypt.c b/crypt.c
index 4c9f0fb..3ebcbb3 100644
--- a/crypt.c
+++ b/crypt.c
@@ -5,12 +5,12 @@
#include <string.h> /* strerror(3) */
#include <unistd.h> /* crypt(3) */
-void error(char *);
+void error(const char *);
void usage(FILE *, int);
int main (int argc, char **argv)
{
- char *hash, *key, *salt;
+ const char *hash, *key, *salt;
int opt;
while ((opt = getopt(argc, argv, "h")) != -1) {
@@ -52,7 +52,7 @@ int main (int argc, char **argv)
/*
* Exit with error error message
*/
-void error(char *message)
+void error(const char *message)
{
fprintf(stderr, "%s\n", message);
exit(EXIT_FAILURE);
@@ -61,7 +61,7 @@ void error(char *message)
/*
* Show usage to given stream, and exit with given code
*/
-void usage(FILE *stream, int status)
+void usage(FILE *stream, const int status)
{
fputs("USAGE: crypt [-h | KEY SALT]\n", stream);
exit(status);