aboutsummaryrefslogtreecommitdiff
path: root/crypt.c
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2020-01-16 18:58:04 +1300
committerTom Ryder <tom@sanctum.geek.nz>2020-01-16 18:58:04 +1300
commit5a1102ccceac1346500afd740296b2d6f95f0f97 (patch)
tree1383d62281c93e859d64123ad214ee3484e503b6 /crypt.c
parentFix and extend GCC options (diff)
downloadcrypt-5a1102ccceac1346500afd740296b2d6f95f0f97.tar.gz
crypt-5a1102ccceac1346500afd740296b2d6f95f0f97.zip
Reorder functions
Diffstat (limited to 'crypt.c')
-rw-r--r--crypt.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/crypt.c b/crypt.c
index 457a245..7ba42ef 100644
--- a/crypt.c
+++ b/crypt.c
@@ -42,19 +42,19 @@ int main (int argc, char **argv)
}
/*
- * Show usage to given stream, and exit with given code
+ * Exit with error error message
*/
-void usage(FILE *stream, int status)
+void error(char *message)
{
- fputs("USAGE: crypt [-h | KEY SALT]\n", stream);
- exit(status);
+ fprintf(stderr, "%s\n", message);
+ exit(EXIT_FAILURE);
}
/*
- * Exit with error error message
+ * Show usage to given stream, and exit with given code
*/
-void error(char *message)
+void usage(FILE *stream, int status)
{
- fprintf(stderr, "%s\n", message);
- exit(EXIT_FAILURE);
+ fputs("USAGE: crypt [-h | KEY SALT]\n", stream);
+ exit(status);
}