ikectl: ikeca.c cleanup: invalid 644 mode

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

ikectl: ikeca.c cleanup: invalid 644 mode

Sebastien Marie-2
Hi,

The following patch corrects an invalid 644 mode to 0644. fcopy() set
the mode using open(3).

The previous mode requested was 1610 (644 in octal), but the value is
modified by umask value.

This file is the zip exported archive.

--
Sebastien Marie


Index: ikeca.c
===================================================================
RCS file: /cvs/src/usr.sbin/ikectl/ikeca.c,v
retrieving revision 1.30
diff -u -p -r1.30 ikeca.c
--- ikeca.c 16 Jan 2015 06:40:17 -0000 1.30
+++ ikeca.c 12 Aug 2015 07:09:38 -0000
@@ -683,7 +683,7 @@ ca_export(struct ca *ca, char *keyname,
     de->d_name);
  snprintf(dst, sizeof(dst), "%s/export/%s", p,
     de->d_name);
- fcopy(src, dst, 644);
+ fcopy(src, dst, 0644);
  }
  closedir(dexp);
  }

Reply | Threaded
Open this post in threaded view
|

Re: ikectl: ikeca.c cleanup: invalid 644 mode

Sebastien Marie-2
On Wed, Aug 12, 2015 at 09:17:35AM +0200, Sebastien Marie wrote:
>
> The previous mode requested was 1610 (644 in octal), but the value is
> modified by umask value.

I need base 8 revision... it was 1204.

--
Sebastien Marie