Fix linting issues: remove redundant build tags and use errors.New

Signed-off-by: Varun Gokulnath <vagokuln@microsoft.com>
Signed-off-by: Varun Gokulnath <gvarun22@outlook.com>
This commit is contained in:
Varun Gokulnath
2025-12-17 11:16:26 -08:00
committed by Varun Gokulnath
parent 94113a48c2
commit 3ffe560692
2 changed files with 6 additions and 7 deletions
+2 -2
View File
@@ -1,11 +1,11 @@
//go:build windows //go:build windows
// +build windows
package winio package winio
import ( import (
"bytes" "bytes"
"encoding/binary" "encoding/binary"
"errors"
"fmt" "fmt"
"strings" "strings"
"unicode/utf16" "unicode/utf16"
@@ -61,7 +61,7 @@ func DecodeReparsePointData(tag uint32, b []byte) (*ReparsePoint, error) {
case reparseTagLxSymlink: case reparseTagLxSymlink:
// LX symlinks store the target as UTF-8 after a 4-byte version field // LX symlinks store the target as UTF-8 after a 4-byte version field
if len(b) < 4 { if len(b) < 4 {
return nil, fmt.Errorf("LX symlink buffer too short") return nil, errors.New("LX symlink buffer too short")
} }
targetBytes := b[4:] targetBytes := b[4:]
for i, c := range targetBytes { for i, c := range targetBytes {
-1
View File
@@ -1,5 +1,4 @@
//go:build windows //go:build windows
// +build windows
package winio package winio