diff options
author | jsing <> | 2014-04-15 13:42:55 +0000 |
---|---|---|
committer | jsing <> | 2014-04-15 13:42:55 +0000 |
commit | 69a8d2dcc19aed0d1116ba2ecd81cce5ae736c94 (patch) | |
tree | f085d85cb06e6b6e1a1b1d52cced54d9f7d7e5f2 /src/lib/libcrypto/o_dir_test.c | |
parent | c7fdfc89ee30180bf262c4b146c1b6e1030083d6 (diff) | |
download | openbsd-69a8d2dcc19aed0d1116ba2ecd81cce5ae736c94.tar.gz openbsd-69a8d2dcc19aed0d1116ba2ecd81cce5ae736c94.tar.bz2 openbsd-69a8d2dcc19aed0d1116ba2ecd81cce5ae736c94.zip |
First pass at applying KNF to the OpenSSL code, which almost makes it
readable. This pass is whitespace only and can readily be verified using
tr and md5.
Diffstat (limited to 'src/lib/libcrypto/o_dir_test.c')
-rw-r--r-- | src/lib/libcrypto/o_dir_test.c | 34 |
1 files changed, 16 insertions, 18 deletions
diff --git a/src/lib/libcrypto/o_dir_test.c b/src/lib/libcrypto/o_dir_test.c index 238717c110..2973458a94 100644 --- a/src/lib/libcrypto/o_dir_test.c +++ b/src/lib/libcrypto/o_dir_test.c | |||
@@ -43,26 +43,24 @@ | |||
43 | #error "No supported platform defined!" | 43 | #error "No supported platform defined!" |
44 | #endif | 44 | #endif |
45 | 45 | ||
46 | int main() | 46 | int |
47 | main() | ||
47 | { | 48 | { |
48 | OPENSSL_DIR_CTX *ctx = NULL; | 49 | OPENSSL_DIR_CTX *ctx = NULL; |
49 | const char *result; | 50 | const char *result; |
50 | 51 | ||
51 | while((result = OPENSSL_DIR_read(&ctx, CURRDIR)) != NULL) | 52 | while ((result = OPENSSL_DIR_read(&ctx, CURRDIR)) != NULL) { |
52 | { | 53 | printf("%s\n", result); |
53 | printf("%s\n", result); | 54 | } |
54 | } | ||
55 | 55 | ||
56 | if (errno) | 56 | if (errno) { |
57 | { | 57 | perror("test_dir"); |
58 | perror("test_dir"); | 58 | exit(1); |
59 | exit(1); | 59 | } |
60 | } | ||
61 | 60 | ||
62 | if (!OPENSSL_DIR_end(&ctx)) | 61 | if (!OPENSSL_DIR_end(&ctx)) { |
63 | { | 62 | perror("test_dir"); |
64 | perror("test_dir"); | 63 | exit(2); |
65 | exit(2); | 64 | } |
66 | } | 65 | exit(0); |
67 | exit(0); | ||
68 | } | 66 | } |