Replace err != 0 with err != nil where possible

This commit is contained in:
gingerBill
2024-08-04 14:57:25 +01:00
parent fc10b781af
commit 93fabf8628
6 changed files with 18 additions and 34 deletions
+2 -2
View File
@@ -271,7 +271,7 @@ _glob :: proc(dir, pattern: string, matches: ^[dynamic]string, allocator := cont
d, derr := os.open(dir, os.O_RDONLY)
if derr != 0 {
if derr != nil {
return
}
defer os.close(d)
@@ -280,7 +280,7 @@ _glob :: proc(dir, pattern: string, matches: ^[dynamic]string, allocator := cont
file_info, ferr := os.fstat(d)
defer os.file_info_delete(file_info)
if ferr != 0 {
if ferr != nil {
return
}
if !file_info.is_dir {