43 lines
1.1 KiB
Diff
43 lines
1.1 KiB
Diff
--- src/link.c
|
|
+++ src/link.c
|
|
@@ -393,6 +393,10 @@
|
|
{ struct stat buf,savebuf;
|
|
char to[CF_BUFSIZE],linkbuf[CF_BUFSIZE],saved[CF_BUFSIZE],absto[CF_BUFSIZE],*lastnode;
|
|
struct UidList fakeuid;
|
|
+ union {
|
|
+ struct UidList *uifakeuid;
|
|
+ struct GidList *gifakeuid;
|
|
+ } ufakeuid = { &fakeuid };
|
|
struct Image ip;
|
|
char stamp[CF_BUFSIZE];
|
|
time_t STAMPNOW;
|
|
@@ -436,7 +440,7 @@
|
|
ip.plus = CF_SAMEMODE;
|
|
ip.minus = CF_SAMEMODE;
|
|
ip.uid = &fakeuid;
|
|
- ip.gid = (struct GidList *) &fakeuid;
|
|
+ ip.gid = ufakeuid.gifakeuid;
|
|
ip.action = "do";
|
|
ip.recurse = 0;
|
|
ip.type = 't';
|
|
@@ -869,6 +873,10 @@
|
|
{ struct stat frombuf,tobuf;
|
|
char saved[CF_BUFSIZE], *lastnode;
|
|
struct UidList fakeuid;
|
|
+ union {
|
|
+ struct UidList *uifakeuid;
|
|
+ struct GidList *gifakeuid;
|
|
+ } ufakeuid = { &fakeuid };
|
|
struct Image ip;
|
|
char stamp[CF_BUFSIZE];
|
|
time_t STAMPNOW;
|
|
@@ -899,7 +907,7 @@
|
|
ip.plus = CF_SAMEMODE;
|
|
ip.minus = CF_SAMEMODE;
|
|
ip.uid = &fakeuid;
|
|
- ip.gid = (struct GidList *) &fakeuid;
|
|
+ ip.gid = ufakeuid.gifakeuid;
|
|
ip.action = "do";
|
|
ip.recurse = 0;
|
|
ip.type = 't';
|