chiark / gitweb /
drop_duplicates: copy full BindMount struct
authorAnsgar Burchardt <ansgar@debian.org>
Sun, 27 Jul 2014 14:32:13 +0000 (16:32 +0200)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Sun, 27 Jul 2014 19:15:11 +0000 (15:15 -0400)
At least

  t->ignore = f->ignore;

is missing here. Just copy the full struct to be sure.

src/core/namespace.c

index 5466b7baec2a8cdd96c40ab5619c49b6f8c98e74..fe9537787185c6755f9778593ae5aa393d760e7a 100644 (file)
@@ -124,8 +124,7 @@ static void drop_duplicates(BindMount *m, unsigned *n) {
                 if (previous && path_equal(f->path, previous->path))
                         continue;
 
                 if (previous && path_equal(f->path, previous->path))
                         continue;
 
-                t->path = f->path;
-                t->mode = f->mode;
+                *t = *f;
 
                 previous = t;
 
 
                 previous = t;