Merge pull request #2825 from AZero13/patch-2

Error check ret before calling copy_seek_stat

(cherry picked from commit e91171c9a0)
This commit is contained in:
Tim Kientzle authored and Martin Matuska committed 2025-12-28 13:13:33 +01:00
1 parent 0793148e77
commit 5d015feb39
1 file changed
+2 -1
+2 -1
View File
@@ -747,7 +747,8 @@ __la_seek_fstat(int fd, la_seek_stat_t *st)
int ret;
ret = __hstat((HANDLE)_get_osfhandle(fd), &u);
copy_seek_stat(st, &u);
if (ret >= 0)
copy_seek_stat(st, &u);
return (ret);
}