Page MenuHomeFreeBSD

bsddialog: in textbox mode differentiate between Exit and Extra buttons
ClosedPublic

Authored by glebius on Jan 24 2025, 7:01 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Oct 12, 4:13 PM
Unknown Object (File)
Sun, Oct 12, 1:24 PM
Unknown Object (File)
Fri, Oct 10, 3:48 PM
Unknown Object (File)
Fri, Oct 10, 3:48 PM
Unknown Object (File)
Fri, Oct 10, 3:48 PM
Unknown Object (File)
Fri, Oct 10, 9:40 AM
Unknown Object (File)
Fri, Oct 10, 3:20 AM
Unknown Object (File)
Mon, Oct 6, 4:01 AM
Subscribers

Details

Summary

If run --extra-button --textbox dialog will have two buttons, but
either of them would return 0 exit status. We definitely want the
Extra to report its value.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

jlduran added a subscriber: jlduran.

After a simple:

grep -r -A3 "case 10" contrib/bsddialog/

I could not find any other occurrence that needs fixing.

This revision is now accepted and ready to land.Jan 25 2025, 2:23 AM

After a simple:

grep -r -A3 "case 10" contrib/bsddialog/

I could not find any other occurrence that needs fixing.

@jlduran Maybe the checks has to be performed inside the "clients" of bsddialog: bsdinstall, (mainly) bsdconfig, tzsetup, spkrtest, and kdbmap to avoid side effects.
Anyway the @glebius 's change makes sense. Honestly I forgot why textbox always returns OK, maybe for compatibility with cdialog. Anyway the next version (and import in contrib/) of bsddialog will have this change.

contrib/bsddialog/lib/textbox.c
203

Ok, this makes sense, honestly I forgot why textbox always returns OK, maybe compatibility with cdialog. Anyway I'll add 2 more changes/feature requests to bsddialog then I'll import a new version with this change.