lkml.org 
[lkml]   [2020]   [May]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] keys: Make the KEY_NEED_* perms an enum rather than a mask
Date
Paul Moore <paul@paul-moore.com> wrote:

> > + case KEY_NEED_VIEW: perm = KEY__VIEW; break;
> > + case KEY_NEED_READ: perm = KEY__READ; break;
> > + case KEY_NEED_WRITE: perm = KEY__WRITE; break;
> > + case KEY_NEED_SEARCH: perm = KEY__SEARCH; break;
> > + case KEY_NEED_LINK: perm = KEY__LINK; break;
> > + case KEY_NEED_SETATTR: perm = KEY__SETATTR; break;
>
> Please don't put the case statements all on one line, use the more
> traditional multi-line format. For example:
>
> case KEY_NEED_SETATTR:
> perm = KEY__SETATTR;
> break;

Tabulation was invented something like 6000 years ago for just this kind of
purpose;-) It's less readable your way, but whatever...

David

\
 
 \ /
  Last update: 2020-05-14 01:16    [W:0.105 / U:1.004 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site