svn commit: r343152 - head/usr.sbin/freebsd-update

Rodney W. Grimes freebsd at pdx.rh.CN85.dnsmgr.net
Fri Jan 18 22:54:39 UTC 2019


> On Fri, 18 Jan 2019 at 12:51, Rodney W. Grimes
> <freebsd at pdx.rh.cn85.dnsmgr.net> wrote:
> >
> > Since your in here fixing... there is a false positive on the
> > detection of what is installed when we zero the size of a set,
> > ie, now that doc.txz is a 0 size set it always thinks you have
> > doc installed due to rounding errors in the calculation that
> > says you have x% of this installed.
> 
> Hi Rod, I'm not sure exactly what you mean here - could you clarify,
> or create a PR with the details?

During the 12.0 release cycle the doc.txz part of the system
went away, we put up an empty tar ball, when freebsd-update
evaluates if you have installed this component it says
you have, even though you have not.

This is caused by function:
upgrade_guess_components () {

when it does this:
	                join -t ' ' -1 2 -2 2 compfreq.present compfreq.total |
                    while read S P T; do
                        if [ ${P} -gt `expr ${T} / 2` ]; then
                                echo ${S}
                        fi
                    done > comp.present

When expr ${T} the count of items in the set is 0 all things
are -gt 0 and so it says the component is present.  This is
an incorrect false positive.

> 
> 

-- 
Rod Grimes                                                 rgrimes at freebsd.org


More information about the svn-src-head mailing list