Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/external/cddl/osnet/dist/lib/libzfs/common Replace another o...



details:   https://anonhg.NetBSD.org/src/rev/d0642d3e0003
branches:  trunk
changeset: 747944:d0642d3e0003
user:      haad <haad%NetBSD.org@localhost>
date:      Tue Oct 06 12:03:47 2009 +0000

description:
Replace another openat call with open + changed path.

XXX. This commit should be reverted after proper implementation of *at syscalls.

diffstat:

 external/cddl/osnet/dist/lib/libzfs/common/libzfs_import.c |  5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diffs (15 lines):

diff -r 05c3eaed50fd -r d0642d3e0003 external/cddl/osnet/dist/lib/libzfs/common/libzfs_import.c
--- a/external/cddl/osnet/dist/lib/libzfs/common/libzfs_import.c        Tue Oct 06 09:12:47 2009 +0000
+++ b/external/cddl/osnet/dist/lib/libzfs/common/libzfs_import.c        Tue Oct 06 12:03:47 2009 +0000
@@ -860,7 +860,10 @@
                            (name[1] == 0 || (name[1] == '.' && name[2] == 0)))
                                continue;
 
-                       if ((fd = openat64(dfd, name, O_RDONLY)) < 0)
+                       (void)snprintf(path, sizeof (path), "%s/%s",
+                           rdsk, dp->d_name);
+                       
+                       if ((fd = open(path, O_RDONLY)) < 0)
                                continue;
 
                        /*



Home | Main Index | Thread Index | Old Index