mirror of
https://codeberg.org/forgejo/forgejo
synced 2024-11-22 01:44:24 +01:00
[CHORE] Fix darwin compatibility
- Always convert (syscall.Stat_t).Dev to uint64. - Resolves #4905
This commit is contained in:
parent
d5ba61a104
commit
ac8856ac2b
|
@ -39,7 +39,9 @@ func fileStatDevIno(file *os.File) (uint64, uint64, bool) {
|
||||||
return 0, 0, false
|
return 0, 0, false
|
||||||
}
|
}
|
||||||
|
|
||||||
return stat.Dev, stat.Ino, true
|
// Do a type conversion to uint64, because Dev isn't always uint64
|
||||||
|
// on every operating system + architecture combination.
|
||||||
|
return uint64(stat.Dev), stat.Ino, true //nolint:unconvert
|
||||||
}
|
}
|
||||||
|
|
||||||
func fileIsDevIno(file *os.File, dev, ino uint64) bool {
|
func fileIsDevIno(file *os.File, dev, ino uint64) bool {
|
||||||
|
|
Loading…
Reference in a new issue