Skip to content

Assume 0755 mode for olddircreate#560

Closed
saper wants to merge 1 commit intologrotate:mainfrom
saper:olddircreate-crazy-mode
Closed

Assume 0755 mode for olddircreate#560
saper wants to merge 1 commit intologrotate:mainfrom
saper:olddircreate-crazy-mode

Conversation

@saper
Copy link
Contributor

@saper saper commented Nov 11, 2023

File mode is optional for create and olddircreate, therefore old directory will be created with mode 037777777777 if not specified.

Copy link
Member

@cgzones cgzones left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Besides the inline nits, LGTM.

the \fBolddir\fR directory will belong to (see the section \fBUSER AND GROUP
\fR for details). This option can be disabled using
the \fBnocreateolddir\fR option.
the \fBnocreateolddir\fR option. If \fImode\fR is not specified, \fB0755\fR is assumed.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally the sentence This option can be disabled using the \fBfoo\fR option. comes last in the other blocks.

rv = readModeUidGid(configFile, lineNum, key, "createolddir",
&newlog->olddirMode, &newlog->olddirUid,
&newlog->olddirGid);
if (newlog->olddirMode == NO_MODE) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Personally I would order this adjustment after the error check.

&newlog->olddirGid);
if (newlog->olddirMode == NO_MODE) {
newlog->olddirMode = 0755;
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please correct the indentation.

@cgzones cgzones mentioned this pull request Jan 5, 2024
8 tasks
@cgzones
Copy link
Member

cgzones commented May 24, 2024

Applied via 47f79e7 with minor formatting adjustments.

Thanks for your contribution!

@cgzones cgzones closed this May 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants