git: DragonFly_RELEASE_6_4 fdisk(8): Clear errno in read_disk() to avoid confusing others

Aaron LI aly at crater.dragonflybsd.org
Fri May 9 01:03:03 PDT 2025


commit b42b35c6491b32f73ceb85a86b7c98f0d3fc8396
Author: Aaron LI <aly at aaronly.me>
Date:   Fri May 9 12:26:10 2025 +0800

    fdisk(8): Clear errno in read_disk() to avoid confusing others
    
    For example, even read_disk() succeeded in detecting the sector size and
    reading, the errno would remain EIO, which could confuse the later code
    that calls err() or others.

Summary of changes:
 sbin/fdisk/fdisk.c | 1 +
 1 file changed, 1 insertion(+)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/b42b35c6491b32f73ceb85a86b7c98f0d3fc8396


-- 
DragonFly BSD source repository


More information about the Commits mailing list