- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 73 for xreaddir (0.14 sec)
-
src/cmd/dist/util.go
func xremoveall(p string) { if vflag > 2 { errprintf("rm -r %s\n", p) } os.RemoveAll(p) } // xreaddir replaces dst with a list of the names of the files and subdirectories in dir. // The names are relative to dir; they are not full paths. func xreaddir(dir string) []string { f, err := os.Open(dir) if err != nil { fatalf("%v", err) } defer f.Close()
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Feb 23 17:50:29 UTC 2023 - 11.2K bytes - Viewed (0) -
src/testing/fstest/testfs.go
t.errorf("%s: third Open: ReadDir(%d) after %d: 0 entries but nil error", dir, n, len(list2)) return } } t.checkDirList(dir, "first Open+ReadDir(-1) vs third Open+ReadDir(1,2) loop", list, list2) // If fsys has ReadDir, check that it matches and is sorted. if fsys, ok := t.fsys.(fs.ReadDirFS); ok { list2, err := fsys.ReadDir(dir) if err != nil { t.errorf("%s: fsys.ReadDir: %w", dir, err) return }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:00:11 UTC 2024 - 16.3K bytes - Viewed (0) -
src/cmd/go/internal/fsys/fsys.go
} fis = append(fis, info) } return fis, nil } // ReadDir provides a slice of fs.FileInfo entries corresponding // to the overlaid files in the directory. func ReadDir(dir string) ([]fs.FileInfo, error) { Trace("ReadDir", dir) dir = canonicalize(dir) if _, ok := parentIsOverlayFile(dir); ok { return nil, &fs.PathError{Op: "ReadDir", Path: dir, Err: errNotDir} } dirNode := overlay[dir]
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Jun 06 18:35:34 UTC 2024 - 22.7K bytes - Viewed (0) -
pkg/volume/fc/fc_util.go
) type ioHandler interface { ReadDir(dirname string) ([]os.FileInfo, error) Lstat(name string) (os.FileInfo, error) EvalSymlinks(path string) (string, error) WriteFile(filename string, data []byte, perm os.FileMode) error } type osIOHandler struct{} const ( byPath = "/dev/disk/by-path/" byID = "/dev/disk/by-id/" ) func (handler *osIOHandler) ReadDir(dirname string) ([]os.FileInfo, error) {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri Sep 16 11:12:06 UTC 2022 - 12.8K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/arch/x86/x86asm/decode.go
xCondAddrSize // switch on address size xCondIsMem // switch on memory vs register argument xSetOp // set instruction opcode xReadSlashR // read /r xReadIb // read ib xReadIw // read iw xReadId // read id xReadIo // read io xReadCb // read cb xReadCw // read cw xReadCd // read cd xReadCp // read cp xReadCm // read cm xArg1 // arg 1
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Feb 10 18:59:52 UTC 2023 - 45.1K bytes - Viewed (0) -
src/embed/embed.go
if file == nil { return nil, &fs.PathError{Op: "open", Path: name, Err: fs.ErrNotExist} } if file.IsDir() { return &openDir{file, f.readDir(name), 0}, nil } return &openFile{file, 0}, nil } // ReadDir reads and returns the entire named directory. func (f FS) ReadDir(name string) ([]fs.DirEntry, error) { file, err := f.Open(name) if err != nil { return nil, err } dir, ok := file.(*openDir)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 20 19:42:51 UTC 2024 - 13.5K bytes - Viewed (0) -
src/net/http/fs.go
// Prefer to use ReadDir instead of Readdir, // because the former doesn't require calling // Stat on every entry of a directory on Unix. var dirs anyDirs var err error if d, ok := f.(fs.ReadDirFile); ok { var list dirEntryDirs list, err = d.ReadDir(-1) dirs = list } else { var list fileInfoDirs list, err = f.Readdir(-1) dirs = list } if err != nil {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 09 17:06:47 UTC 2024 - 31.1K bytes - Viewed (0) -
src/os/os_unix_test.go
d, err := Open(dir) if err != nil { t.Fatal(err) } defer d.Close() fis, err := d.Readdir(2) // notably, greater than zero if len(fis) == 0 && err == nil { // This is what used to happen (Issue 16919) t.Fatal("Readdir = empty slice & err == nil") } if len(fis) != 0 || err != io.EOF { t.Errorf("Readdir = %d entries: %v; want 0, io.EOF", len(fis), err) for i, fi := range fis {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Sep 18 17:32:43 UTC 2023 - 11.5K bytes - Viewed (0) -
pkg/volume/emptydir/empty_dir.go
// In this case, delete ready file and print a warning for it. klog.Warningf("volume ready file dir %s exist, but volume dir %s does not. Remove ready dir", readyDir, dir) if err := os.RemoveAll(readyDir); err != nil && !os.IsNotExist(err) { klog.Warningf("failed to remove ready dir [%s]: %v", readyDir, err) } } } switch { case ed.medium == v1.StorageMediumDefault: err = ed.setupDir(dir)
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue May 21 10:18:16 UTC 2024 - 19K bytes - Viewed (0) -
pkg/kubelet/logs/container_log_manager_test.go
}() // This is a blocking call. But the above routine takes care of ensuring that this is terminated once the queue is shutdown c.processQueueItems(ctx, 1) timestamp := now.Format(timestampFormat) logs, err := os.ReadDir(dir) require.NoError(t, err) assert.Len(t, logs, 5) assert.Equal(t, testLogs[0], logs[0].Name()) assert.Equal(t, testLogs[1]+"."+timestamp, logs[1].Name()) assert.Equal(t, testLogs[4]+compressSuffix, logs[2].Name())
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Sat May 04 18:33:12 UTC 2024 - 12.7K bytes - Viewed (0)