func Readdirnames(fd *FD, count int) (names []string, err *os.Error) {
// If this fd has no dirinfo, create one.
if fd.dirinfo == nil {
- fd.dirinfo = new(DirInfo);
+ fd.dirinfo = new(dirInfo);
// The buffer must be at least a block long.
// TODO(r): use fstatfs to find fs block size.
fd.dirinfo.buf = make([]byte, blockSize);
func Readdirnames(fd *FD, count int) (names []string, err *os.Error) {
// If this fd has no dirinfo, create one.
if fd.dirinfo == nil {
- fd.dirinfo = new(DirInfo);
+ fd.dirinfo = new(dirInfo);
// The buffer must be at least a block long.
// TODO(r): use fstatfs to find fs block size.
fd.dirinfo.buf = make([]byte, blockSize);
import os "os"
// Auxiliary information if the FD describes a directory
-type DirInfo struct { // TODO(r): 6g bug means this can't be private
+type dirInfo struct { // TODO(r): 6g bug means this can't be private
buf []byte; // buffer for directory I/O
nbuf int64; // length of buf; return value from Getdirentries
bufp int64; // location of next record in buf.
type FD struct {
fd int64;
name string;
- dirinfo *DirInfo; // nil unless directory being read
+ dirinfo *dirInfo; // nil unless directory being read
}
func (fd *FD) Fd() int64 {