Openwall GNU/*/Linux - a small security-enhanced Linux distro for servers
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Sun, 21 Jun 2015 12:42:47 +0800
From: Kai Zhao <loverszhao@...il.com>
To: john-dev@...ts.openwall.com
Subject: Re: Coding Style

Hi Alexander,

> I'd prefer the alignment to be completely gone, though.  My old style
> was to use a tab for continuation lines as well.  My newer style is to
> use 4 spaces there, which is visibly different when tabs are 8 chars.
> So this would be:

>>        fprintf(stderr, "Only one OpenCL device"
>>           " supported with --platform syntax.\n");

> Incidentally, 4 chars happens to match alignment to opening brace for
> if's.

As to function declaration, use a tab or 4 spaces?

use a tab
------------

loader.c  line: 44

static void read_file(struct db_main *db, char *name, int flags,
        void (*process_line)(struct db_main *db, char *line))


use 4 spaces
------------------

formats.c line: 50

static char *fmt_self_test_body(struct fmt_main *format,
    void *binary_copy, void *salt_copy)



Thanks,

Kai

[ CONTENT OF TYPE text/html SKIPPED ]

Powered by blists - more mailing lists

Your e-mail address:

Powered by Openwall GNU/*/Linux - Powered by OpenVZ