HomeFreeBSD

Endless loop in zpool_do_remove() on platforms with unsigned char

Description

Endless loop in zpool_do_remove() on platforms with unsigned char

On systems where "char" is an unsigned type the value returned by
getopt() will never be negative (-1), leading to an endless loop:
this issue prevents both 'zpool remove' and 'zstreamdump' for
working on some systems.

Reviewed-by: Igor Kozhukhov <igor@dilos.org>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Chris Dunlop <chris@onthe.net.au>
Signed-off-by: loli10K <ezomori.nozomu@gmail.com>
Closes #8789

Details

Provenance
loli10K <loli10K@users.noreply.github.com>Authored on May 28 2019, 6:14 PM
Brian Behlendorf <behlendorf1@llnl.gov>Committed on May 28 2019, 6:14 PM
Parents
rG841a7a98fc46: Update descriptions for vnops
Branches
Unknown
Tags
Unknown

Event Timeline

Brian Behlendorf <behlendorf1@llnl.gov> committed rG0869b74a1edc: Endless loop in zpool_do_remove() on platforms with unsigned char (authored by loli10K <loli10K@users.noreply.github.com>).May 28 2019, 6:14 PM