mirror of
https://github.com/emmansun/gmsm.git
synced 2025-04-26 12:16:20 +08:00
fix bug
This commit is contained in:
parent
c2efe31957
commit
a507f61c7c
@ -78,9 +78,9 @@ func loadSystemRoots() (*CertPool, error) {
|
||||
return nil, firstErr
|
||||
}
|
||||
|
||||
// readUniqueDirectoryEntries is like ioutil.ReadDir but omits
|
||||
// readUniqueDirectoryEntries is like os.ReadDir but omits
|
||||
// symlinks that point within the directory.
|
||||
func readUniqueDirectoryEntries(dir string) ([]os.FileInfo, error) {
|
||||
func readUniqueDirectoryEntries(dir string) ([]fs.DirEntry, error) {
|
||||
files, err := os.ReadDir(dir)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
@ -94,6 +94,7 @@ func readUniqueDirectoryEntries(dir string) ([]os.FileInfo, error) {
|
||||
return uniq, nil
|
||||
}
|
||||
|
||||
|
||||
// isSameDirSymlink reports whether fi in dir is a symlink with a
|
||||
// target not containing a slash.
|
||||
func isSameDirSymlink(f fs.DirEntry, dir string) bool {
|
||||
|
Loading…
x
Reference in New Issue
Block a user