On Wed, Nov 02, 2011 at 09:56:17AM +0100, Thorsten Kukuk wrote:
On Wed, Nov 02, Tomas Mraz wrote:
> On Wed, 2011-11-02 at 05:49 +0400, Dmitry V. Levin wrote:
> > On Tue, Nov 01, 2011 at 08:37:40PM +0100, Tomas Mraz wrote:
[...]
> > >
> > > A few comments - I am not too fond of the reindentation commit. Although
> > > the indentation in pam_selinux.c is ugly and mixing styles I do not
> > > think this brings us much, but it surely makes things harder to review
> > > or backport patches into older versions, etc.
> >
> > I am also not too fond of reindentation, but I had a poor choice. The
> > indentation in pam_selinux.c is indeed very ugly, and the next commit
> > changes quite a lot of code anyway: "reindent" commit does
> > 353 insertions and 339 deletions, and "rewrite" commit does
> > 328 insertions and 257 deletions. There are several functions affected by
> > re-indentation but not affected by later rewrite (send_audit_message,
> > send_text, query_response, manual_context, mls_range_allowed,
> > config_context and context_from_env). It is technically possible to
> > revert that part of the reindentation commit, but this would mean that the
> > whole indentation will remain ugly and mixing styles. Also, it is not too
> > late to adjust the indentation style itself, it is not strictly necessary
> > to choose the style used in larger part of pam_selinux.c code.
> I'd really want to see the opinion of Thorsten or Steve. I am OK with
> the reindentation if they are OK with it as well.
Our agreement some years(?) ago was, that everybody should
us the indentation style he likes best for "his" modules, but
that the indentation style inside of one source file should be
consistent.
Unfortunately, this agreement was certainly not followed in case of
pam_selinux.c, otherwise its indentation style wouldn't be mixed so much.
And that we didn't want to change the indentation, because this
would make tracking the changes and reading patches very difficult.
This approach may serve well for normal files where the indentation style
is consistent, but how to apply it for pam_selinux.c with its mixed
indentation? Should we try to maintain this indentation diversity in one
file, or should we better try to bring some consistency in pam_selinux.c
before another change which essentially rewrites a large part of this file
anyway?
--
ldv